From 22af21b7a24929664deea6ab083106b9eceb37e8 Mon Sep 17 00:00:00 2001 From: Evgeni Golov Date: Wed, 3 Jan 2024 09:03:17 +0100 Subject: [PATCH] Fix pinning of NodeJS 18 on Debian 12 in tests --- spec/acceptance/class_spec.rb | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/spec/acceptance/class_spec.rb b/spec/acceptance/class_spec.rb index 6841c736..ad65fac0 100644 --- a/spec/acceptance/class_spec.rb +++ b/spec/acceptance/class_spec.rb @@ -34,9 +34,10 @@ include_examples 'cleanup' - # Debian 12 contains NodeJS 18, when we test 16, we need to force the nodesource version + # Debian 12 contains NodeJS 18, when we test 16 and 18, we need to force the nodesource version + # as Debians versions *can* be newer repo_pin = - if nodejs_version == '16' && fact('os.family') == 'Debian' && fact('os.release.major') == '12' + if %w[16 18].include?(nodejs_version) && fact('os.family') == 'Debian' && fact('os.release.major') == '12' '1000' else 'undef'