fixed bdd tests

This commit is contained in:
2026-04-08 12:05:11 +02:00
parent f34a41a1c7
commit f013a1771d
2 changed files with 3 additions and 2 deletions

View File

@@ -77,7 +77,7 @@ func InitializeAllSteps(ctx *godog.ScenarioContext, client *testserver.Client) {
ctx.Step(`^I authenticate with username "([^"]*)" and password "([^"]*)" again$`, sc.authSteps.iAuthenticateWithUsernameAndPasswordAgain)
// Common steps
ctx.Step(`^the response should be "{\"([^"]*)\":\"([^"]*)"}"$`, sc.commonSteps.theResponseShouldBe)
ctx.Step(`^the response should be "{\\"([^"]*)":\\"([^"]*)"}"$`, sc.commonSteps.theResponseShouldBe)
ctx.Step(`^the response should contain error "([^"]*)"$`, sc.commonSteps.theResponseShouldContainError)
ctx.Step(`^the status code should be (\d+)$`, sc.commonSteps.theStatusCodeShouldBe)
}

View File

@@ -6,7 +6,7 @@
set -e
echo "🧪 Running BDD Tests..."
cd /Users/gabrielradureau/Work/Vibe/dance-lessons-coach
cd /Users/gabrielradureau/Work/Vibe/DanceLessonsCoach
# Check if PostgreSQL container is running, start it if not
echo "🐋 Checking PostgreSQL container..."
@@ -90,5 +90,6 @@ if [ $test_exit_code -eq 0 ]; then
exit 0
else
echo "❌ BDD tests failed"
echo 'DLC_DATABASE_HOST=localhost DLC_DATABASE_PORT=5432 DLC_DATABASE_USER=postgres DLC_DATABASE_PASSWORD=postgres DLC_DATABASE_NAME=dance_lessons_coach_bdd_test DLC_DATABASE_SSL_MODE=disable go test ./features/... -v'
exit 1
fi