From 6c7dd5d0f525a119e33096cdb9af8a6639c5707f Mon Sep 17 00:00:00 2001 From: Kristen Brown Date: Thu, 30 Mar 2023 17:13:21 -0400 Subject: [PATCH] API-24392: Remove test feature from `VBADocuments` enabled_features config (#12300) * API-24392: Remove test feature from enabled_features config --- modules/vba_documents/config/flipper/enabled_features.yml | 1 - .../vba_documents/spec/workers/flipper_status_alert_spec.rb | 4 ++++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/modules/vba_documents/config/flipper/enabled_features.yml b/modules/vba_documents/config/flipper/enabled_features.yml index 20ea1052b38..4664d7ba43b 100644 --- a/modules/vba_documents/config/flipper/enabled_features.yml +++ b/modules/vba_documents/config/flipper/enabled_features.yml @@ -1,5 +1,4 @@ common: - - test_feature_flag_alert_temp development: staging: sandbox: diff --git a/modules/vba_documents/spec/workers/flipper_status_alert_spec.rb b/modules/vba_documents/spec/workers/flipper_status_alert_spec.rb index 74841e71580..6aceef6c58a 100644 --- a/modules/vba_documents/spec/workers/flipper_status_alert_spec.rb +++ b/modules/vba_documents/spec/workers/flipper_status_alert_spec.rb @@ -91,6 +91,7 @@ end it 'does not notify Slack when all features are enabled' do + allow(YAML).to receive(:load_file).and_return({ 'common' => %w[feature1 feature2] }) bulk_checker_result = { enabled: %w[feature1 feature2], disabled: [], missing: [] } allow(Flipper::Utilities::BulkFeatureChecker).to receive(:enabled_status).and_return(bulk_checker_result) expect(VBADocuments::Slack::Messenger).not_to receive(:new) @@ -99,6 +100,7 @@ end it 'notifies Slack when some features are disabled' do + allow(YAML).to receive(:load_file).and_return({ 'common' => %w[feature1 feature2 feature3] }) bulk_checker_result = { enabled: %w[feature1], disabled: %w[feature2 feature3], missing: [] } allow(Flipper::Utilities::BulkFeatureChecker).to receive(:enabled_status).and_return(bulk_checker_result) expected_notify = { @@ -114,6 +116,7 @@ end it 'notifies Slack when some features are missing' do + allow(YAML).to receive(:load_file).and_return({ 'common' => %w[feature1 feature2 feature3] }) bulk_checker_result = { enabled: %w[feature1], disabled: [], missing: %w[feature2 feature3] } allow(Flipper::Utilities::BulkFeatureChecker).to receive(:enabled_status).and_return(bulk_checker_result) expected_notify = { @@ -129,6 +132,7 @@ end it 'notifies slack when there are disabled and missing features' do + allow(YAML).to receive(:load_file).and_return({ 'common' => %w[feature1 feature2 feature3 feature4 feature5] }) bulk_checker_result = { enabled: %w[feature1], disabled: %w[feature2 feature3], missing: %w[feature4 feature5] } allow(Flipper::Utilities::BulkFeatureChecker).to receive(:enabled_status).and_return(bulk_checker_result) expected_notify = {