feat(qe-m3-05): complete scores frontend DOM verification E2E test and fix Gitea CI migration sequence
This commit is contained in:
@@ -104,8 +104,8 @@ namespace QuantEngine.Core.Tests
|
||||
using var conn = new NpgsqlConnection(successfulConnStr);
|
||||
await conn.OpenAsync();
|
||||
|
||||
// Create engine_history schema and table
|
||||
await conn.ExecuteAsync("CREATE SCHEMA IF NOT EXISTS engine_history;");
|
||||
|
||||
await conn.ExecuteAsync(@"
|
||||
CREATE TABLE IF NOT EXISTS engine_history.factor_output_history (
|
||||
id BIGSERIAL PRIMARY KEY,
|
||||
@@ -120,7 +120,46 @@ namespace QuantEngine.Core.Tests
|
||||
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
|
||||
);
|
||||
");
|
||||
Console.WriteLine("Explicit schema generation complete.");
|
||||
|
||||
// Create quantengine schema and account tables
|
||||
await conn.ExecuteAsync("CREATE SCHEMA IF NOT EXISTS quantengine;");
|
||||
await conn.ExecuteAsync(@"
|
||||
CREATE TABLE IF NOT EXISTS quantengine.workspace_account (
|
||||
ordinal INT NOT NULL,
|
||||
username TEXT PRIMARY KEY,
|
||||
password_hash TEXT NOT NULL,
|
||||
role TEXT NOT NULL DEFAULT 'Admin',
|
||||
is_active TEXT NOT NULL DEFAULT 'true',
|
||||
created_at TEXT NOT NULL,
|
||||
updated_at TEXT NOT NULL
|
||||
);
|
||||
");
|
||||
|
||||
// Insert admin user
|
||||
await conn.ExecuteAsync(@"
|
||||
INSERT INTO quantengine.workspace_account (
|
||||
ordinal,
|
||||
username,
|
||||
password_hash,
|
||||
role,
|
||||
is_active,
|
||||
created_at,
|
||||
updated_at
|
||||
)
|
||||
VALUES (
|
||||
1,
|
||||
'admin',
|
||||
'4CA7545981323E02F374EC9CB283D658E66F0682822801E4953435188CDCD410',
|
||||
'Admin',
|
||||
'true',
|
||||
NOW()::text,
|
||||
NOW()::text
|
||||
)
|
||||
ON CONFLICT (username) DO UPDATE
|
||||
SET password_hash = EXCLUDED.password_hash;
|
||||
");
|
||||
|
||||
Console.WriteLine("Explicit schema generation and admin seeding complete.");
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user