Skip to content

Remove MC from Azure Appframework Tests (Phase 2)#1870

Draft
gabrielm-splunk wants to merge 17 commits into
developfrom
remove-mc-azure-gcp-appframework-phase2
Draft

Remove MC from Azure Appframework Tests (Phase 2)#1870
gabrielm-splunk wants to merge 17 commits into
developfrom
remove-mc-azure-gcp-appframework-phase2

Conversation

@gabrielm-splunk

Copy link
Copy Markdown
Collaborator

Phase 2 of MC removal - Azure appframework tests cleaned. 1,129 lines removed across 4 files. All compile successfully. Estimated 2-3 hours test time savings.

gabrielm-splunk and others added 13 commits April 16, 2026 14:32
Version 3.0.0 was inadvertently removed by automated PR (commit 1139fcf)
when 3.1.0 was added. Customers reported the version missing from
`helm search repo` results.

Changes:
- Restored 3.0.0 packaged chart from git tag
- Added 3.0.0 entries to docs/index.yaml for both splunk-enterprise and splunk-operator charts
- Chart digest: db5890e3bcc95f9ca7298873cc08b4a5d1ee86ccb4ad4e5334a0ab5d7a5fdb5e

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Update index.yaml with correct SHA256 digests matching actual tarballs:
- splunk-enterprise-3.0.0: ae82f6c8edee4d827817fe6c9c6447c422a03c59595a0f6e779cef847a83b611
- splunk-operator-3.0.0: bd318b1f4022421a3fd429b186ca344c61d04a3c2bbdd5cc535d960773558e44

Resolves comment from vivekr-splunk on PR #1832

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit addresses four vulnerability findings from the container scanner:

- VULN-71179: Upgrade github.com/aws/aws-sdk-go-v2/service/s3 from v1.84.1 to v1.99.0
- VULN-71171: Upgrade go.opentelemetry.io/otel/sdk from v1.40.0 to v1.43.0
- VULN-71183: Upgrade github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream from v1.6.11 to v1.7.8
- VULN-71182: Upgrade Go stdlib from v1.25.8 to v1.26.2

All dependency updates meet or exceed the minimum versions required by the
container scanner. Unit tests pass with 83.6% composite coverage.

Jira: VULN-71179, VULN-71171, VULN-71183, VULN-71182

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Update Go version references in build configuration files to match
the go.mod update for VULN-71182 compliance.

Files updated:
- Dockerfile: golang:1.25.8 -> golang:1.26.2
- Dockerfile.distroless: golang:1.25.8 -> golang:1.26.2
- .env: GO_VERSION=1.25.8 -> GO_VERSION=1.26.2

GitHub Actions workflows automatically use GO_VERSION from .env,
so no workflow file changes are needed.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Introduce a feature gate registry backed by k8s.io/component-base/featuregate
so new capabilities can be gated behind --feature-gates=<Gate>=true|false with
Alpha/Beta/GA lifecycle. Migrate the validation webhook toggle from the
ENABLE_VALIDATION_WEBHOOK env var to a ValidationWebhook feature gate with
backwards-compatible env var support.

- Add pkg/config/featuregates.go registry with SetupFeatureGates and
  IsFeatureGateEnabled helpers, plus unit tests
- Wire feature gate flags into cmd/main.go and log effective gate states
  at startup
- Use os.LookupEnv for ENABLE_VALIDATION_WEBHOOK so the deprecation
  warning fires whenever the env var is set, not just when it equals "true"
- Update kustomization files with SPLUNK_GENERAL_TERMS value
- Add docs/FeatureGates.md with usage and instructions for adding new gates
- Update docs/ValidationWebhook.md with CLI-over-env-var precedence note
* Embed values

* Embed values

* Move fixtures

* Fix copyrights
Fix container scan vulnerabilities (VULN-71179, VULN-71171, VULN-71183, VULN-71182)
Restore helm chart version 3.0.0 to repository index
Add splunkOperator.featureGates map to values so operators can
enable feature gates via helm install/upgrade without per-gate
chart modifications. A helper template formats the map into a
single --feature-gates=Key1=true,Key2=false arg; the deployment
template conditionally includes it when the map is non-empty.

Also introduces helm-unittest with Makefile targets (helm-lint,
helm-test, helm-check) and fixes a pre-existing nindent bug in
the extraEnvs rendering.
* upgrade moby/spdystream version

* update ubi8 minimal image
* Feature/CSPL-4397 Eliminate reliance on time in tests (#1735)

* CSPL-4397 Remove time dependency from tests

* CSPL-4397 Removing test reliance on time

* CSPL-4397 Adjusting timeouts

* CSPL-4354 Fixing time dependencies in unit tests and fixing timeouts in integ tests

* CSPL-4397 Move to using watch

* CSPL-4397 Refactor pod reset detection to use UID-based tracking instead of time-based comparison, add fail-fast test prerequisites validation, and improve code clarity with variable renaming

* CSPL-4397 Refactoring

* CSPL-4397 Addressing comments

* CSPL-4602 Moving duplicated code for LM tests to a shared codebase (#1768)

* CSPL-4602 Moving duplicated code for LM tests to a shared codebase

* CSPL-4602 Addinf license manager tests to workflows

* CSPL-4602 Address comments

* CSPL-4602 Moving LM shared test utils to licensemanager package

* CSPL-4602 Addressing base branch changes

* Feature/cspl 4377 remove panic from test (#1777)

* CSPL-4377 Get rid of not expected panic in tests

* CSPL-4377 Check error for app disablement in tests

* CSPL-3775 Extract setup/teardown functions

* CSPL-3775 Extract common code for secret tests

* CSPL-3775 Extract CRUD common code

* CSPL-3775 Extract common code for smartstore tests

* CSPL-3775 Combining code into re-usable functions

* CSPL-3775 Fix pipeline issues after the changes

* CSPL-3775 Refactoring app fw tests to use before each and after each  code

* CSPL-3775 Extracting common constants

* CSPL-3775 Ingest functions

* CSPL-3775 Move verify prerequisites to setup

* CSPL-3775 Remove constants that already exist

* CSPL-3775 Standardizing suite_test.go

* CSPL-3775 Remove unused functions

* CSPL-3775 Replcaing duplicates among different tests

* CSPL-3775 Eliminating duplicated v3/v4 branching logic

* CSPL-3775 Each test case delegates to a shared Run*Test function, keeping the test file as a thin dispatch layer

* CSPL-3775 Standardize test code by fixing typos in log messages/comments, removing duplicate helpers, replacing inline logic with shared utilities

* CSPL-3775 Consistency improvements

* Fix Silent Failures  (#1785)

* Enhance error handling in WaitforPhaseChange and fix variable name in NewTestCaseEnv

* Updated WaitforPhaseChange to log an error if the phase transition is not observed within the timeout.
* Corrected the variable name check in NewTestCaseEnv to use the provided name instead of an uninitialized envName.
* Changed Kind from "ClusterManager" to "ClusterMaster" in ClusterMaster struct.

* Update error logging in WaitforPhaseChange to use Error level for timeout observations

* CSPL-3775 Refactoring - common naming, format and making sure functinality is not malformed

* CSPL-3775 Eliminate duplicated verification patterns, fix redundant code, and standardize naming, godoc comments, and constants for consistency

* CSPL-3775 Reorganizing utils

* CSPL-3775 Removing gomega/ginkgo from utils

* CSPL-3775 Addressing timeout comments

* CSPL-3775 Fix test failures

* CSPL-3665 Fix License Manager tests

* CSPL-3775 Removing duplicates

* CSPL-3775 Move assertions out of helper functions

* CSPL-3775 Remove redundant inputs

* CSPL-3775 Final polishing to remove duplicates and make codebase more consistent

* CSPL-3775 Restoring accidentally removed test cases

* CSPL-3775 Making some improvements

* CSPL-3775 Adjust timeouts

* CSPL-4378 Adding timeout to app fw verification

* CSPL-4378 Fix failing managersmartstore test

* CSPL-3775 Revert changes that only match v3, skipped for v4

* CSPL-3775 Restoring backward compatibility

* CSPL-3775 Add missing assertions

* CSPL-3775 Add missing assertions

* CSPL-3775 Fixing manager smart store tests

* CSPL-3775 Increase timeout for app fw

* CSPL-3775 Adjust timeouts

* CSPL-3775 Increasing timeouts

* CSPL-3775 Fix introduced backward incompatibility

* CSPL-3775 Fix failing helm tests

---------

Co-authored-by: Jakub Buczak <jbuczak@splunk.com>
Restores the correct splunk-operator-3.0.0.tgz (5.8KB) that contains
only the operator chart, not the full splunk-enterprise chart (4.5MB).

The corrupted file was causing Helm test failures with nil pointer errors.
Extracted correct version from commit a3737ba.

Related to PR #1832 helm test failures.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@gabrielm-splunk gabrielm-splunk force-pushed the remove-mc-azure-gcp-appframework-phase2 branch from 3c9111c to babfce8 Compare April 23, 2026 20:37
@gabrielm-splunk gabrielm-splunk changed the base branch from main to develop April 23, 2026 20:39
gabrielm-splunk and others added 4 commits April 23, 2026 23:16
…0-tgz

Fix corrupted splunk-operator-3.0.0.tgz causing Helm test failures
Removes unnecessary Monitoring Console deployments from Azure
appframework test suite (s1, m4, c3). MC is not the test subject
in these tests, just an incidental deployment adding 4-9 minutes
overhead per test.

Changes:
- Remove MC deployment sections (Azure uploads, app framework specs)
- Remove MonitoringConsoleRef from CR specs
- Pass empty string for mcRef parameters in deployment functions
- Remove MC verification calls (VerifyMonitoringConsoleReady)
- Remove MC app source info from verification arrays
- Remove MC pod arrays from verification logic
- Update test comments to remove MC references

Files Modified:
✓ test/appframework_az/s1/appframework_azure_test.go - 746 lines removed
✓ test/appframework_az/m4/appframework_azure_test.go - 236 lines removed
✓ test/appframework_az/c3/appframework_azure_test.go - 81 lines removed
✓ test/appframework_az/c3/manager_appframework_azure_test.go - 66 lines removed

Total: 1,129+ lines removed, all files compile successfully

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Removes remaining Monitoring Console code from the Azure M4 manager
appframework test file to fully complete Phase 2.

Changes:
- Remove all MC upload sections (azTestDirMC)
- Remove MC spec creation and deployment calls
- Remove MC verification calls (VerifyMonitoringConsoleReady)
- Remove MC from all app source info arrays
- Update deployment calls to pass empty string for mcRef
- Remove unused corev1 import
- Fix variable declarations

File: test/appframework_az/m4/manager_appframework_azure_test.go
Lines removed: 106 lines (2517 → 2411)
MC references remaining: 0

All Azure files now fully cleaned and compile successfully.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants