* HH-441: harden durable storage and recovery * HH-441: clear recovery review blockers * HH-441: enforce offsite backup failure domain --------- Co-authored-by: Rogee <rogee@ipao.vip>
15 lines
415 B
Go
15 lines
415 B
Go
package app
|
|
|
|
import (
|
|
"testing"
|
|
|
|
"github.com/gochat/gochat/internal/config"
|
|
"github.com/stretchr/testify/require"
|
|
)
|
|
|
|
func TestValidateStartupMigrations(t *testing.T) {
|
|
cfg := &config.Config{Database: config.DatabaseConfig{RunMigrations: true}}
|
|
require.ErrorContains(t, validateStartupMigrations("production", cfg), "one-shot migration job")
|
|
require.NoError(t, validateStartupMigrations("development", cfg))
|
|
}
|