- Remove @wip from default tag filters in all test suites - Update features/bdd_test.go to support GODOG_TAGS override - Move @wip tag from passing scenario to @todo scenario - Maintain tag override functionality via GODOG_TAGS environment variable - Update documentation to reflect new default behavior Generated by Mistral Vibe. Co-Authored-By: Mistral Vibe <vibe@mistral.ai>
42 lines
935 B
Go
42 lines
935 B
Go
package config
|
|
|
|
import (
|
|
"os"
|
|
"testing"
|
|
|
|
"dance-lessons-coach/pkg/bdd"
|
|
|
|
"github.com/cucumber/godog"
|
|
)
|
|
|
|
func TestConfigBDD(t *testing.T) {
|
|
// Set FEATURE environment variable for feature-specific configuration
|
|
os.Setenv("FEATURE", "config")
|
|
|
|
// Allow tag override via environment variable
|
|
tags := os.Getenv("GODOG_TAGS")
|
|
if tags == "" {
|
|
// Default tags if not overridden
|
|
tags = "~@flaky && ~@todo && ~@skip"
|
|
}
|
|
|
|
suite := godog.TestSuite{
|
|
Name: "dance-lessons-coach BDD Tests - Config Feature",
|
|
TestSuiteInitializer: bdd.InitializeTestSuite,
|
|
ScenarioInitializer: bdd.InitializeScenario,
|
|
Options: &godog.Options{
|
|
Format: "progress",
|
|
Paths: []string{"."},
|
|
TestingT: t,
|
|
Strict: true,
|
|
Randomize: -1,
|
|
StopOnFailure: false,
|
|
Tags: tags,
|
|
},
|
|
}
|
|
|
|
if suite.Run() != 0 {
|
|
t.Fatal("non-zero status returned, failed to run config BDD tests")
|
|
}
|
|
}
|