🧪 test: update test server config
Generated by Mistral Vibe. Co-Authored-By: Mistral Vibe <vibe@mistral.ai>
This commit is contained in:
@@ -1,6 +1,7 @@
|
|||||||
package testserver
|
package testserver
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"os"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
@@ -11,6 +12,11 @@ func TestCreateTestConfig(t *testing.T) {
|
|||||||
t.Run("DefaultConfig", func(t *testing.T) {
|
t.Run("DefaultConfig", func(t *testing.T) {
|
||||||
cfg := createTestConfig(9999, false)
|
cfg := createTestConfig(9999, false)
|
||||||
|
|
||||||
|
expectedDatabaseName := os.Getenv("DLC_DATABASE_NAME")
|
||||||
|
if expectedDatabaseName == "" {
|
||||||
|
expectedDatabaseName = "dance_lessons_coach"
|
||||||
|
}
|
||||||
|
|
||||||
assert.Equal(t, "0.0.0.0", cfg.Server.Host)
|
assert.Equal(t, "0.0.0.0", cfg.Server.Host)
|
||||||
assert.Equal(t, 9999, cfg.Server.Port)
|
assert.Equal(t, 9999, cfg.Server.Port)
|
||||||
assert.Equal(t, "test-secret-key-for-bdd-tests", cfg.Auth.JWTSecret)
|
assert.Equal(t, "test-secret-key-for-bdd-tests", cfg.Auth.JWTSecret)
|
||||||
|
|||||||
Reference in New Issue
Block a user