From 123ba9ece85ffc149a7ce4e8c433266cabba9d4f Mon Sep 17 00:00:00 2001 From: Takashi Kajinami Date: Mon, 18 Aug 2025 22:14:40 +0900 Subject: [PATCH] Do not disable strict_variables check Starting from 8, puppet requires that all variables are defined in advance. Enable the check to detect any potential problems. Change-Id: Iffca5cbf2719e98d7f188f97871fb29caac37a8e Signed-off-by: Takashi Kajinami --- playbooks/run-libraries-unit-tests.yaml | 7 ------- playbooks/run-unit-tests.yaml | 7 ------- 2 files changed, 14 deletions(-) diff --git a/playbooks/run-libraries-unit-tests.yaml b/playbooks/run-libraries-unit-tests.yaml index 57edfb2c0..fb9135644 100644 --- a/playbooks/run-libraries-unit-tests.yaml +++ b/playbooks/run-libraries-unit-tests.yaml @@ -10,13 +10,6 @@ if [ "{{ rspec_puppet_version }}" != "latest" ]; then export RSPEC_PUPPET_VERSION='{{ rspec_puppet_version }}' fi - # NOTE(aschultz): rspec-puppet 2.4+ has strict variables enabled - # which causes test failures. The problem is that the puppet modules - # have never worked with strict_variables = true due to backwards - # compatibility & import ordering. Since this has not been true, - # lets disable it in the unit testing for now. Perhaps some day - # we will be able to turn this back to true. - export STRICT_VARIABLES=no ./run_unit_tests.sh executable: /bin/bash chdir: '{{ ansible_user_dir }}/workspace' diff --git a/playbooks/run-unit-tests.yaml b/playbooks/run-unit-tests.yaml index 19bb815e5..ead53c958 100644 --- a/playbooks/run-unit-tests.yaml +++ b/playbooks/run-unit-tests.yaml @@ -9,13 +9,6 @@ if [ "{{ rspec_puppet_version }}" != "latest" ]; then export RSPEC_PUPPET_VERSION='{{ rspec_puppet_version }}' fi - # NOTE(aschultz): rspec-puppet 2.4+ has strict variables enabled - # which causes test failures. The problem is that the puppet modules - # have never worked with strict_variables = true due to backwards - # compatibility & import ordering. Since this has not been true, - # lets disable it in the unit testing for now. Perhaps some day - # we will be able to turn this back to true. - export STRICT_VARIABLES=no mkdir .bundled_gems export GEM_HOME=`pwd`/.bundled_gems export GEM_BIN_DIR=$GEM_HOME/bin