Require release versions for script uploads
CI / checks (push) Successful in 5m26s

This commit is contained in:
2026-10-12 18:46:57 -04:00
parent ffda04f276
commit 2f52dcb1ef
50 changed files with 871 additions and 113 deletions
+7 -1
View File
@@ -92,6 +92,7 @@ describe('multi-server blueprints', () => {
const { previewCreation } = await import('../../src/lib/server/fleet/create.js');
const { db, closeDb } = await import('../../src/lib/server/db/index.js');
const artifact = createScript({
releaseVersion: '1.0.0',
name: 'Telemetry',
targetRelPath: 'telemetry.gsc',
scopeType: 'game',
@@ -107,7 +108,12 @@ describe('multi-server blueprints', () => {
'INSERT INTO server_blueprints (id,name,created_at,recipe) VALUES (?, ?, ?, ?)'
)
.run('legacy', 'Old favorite', new Date().toISOString(), JSON.stringify(recipe));
const current = uploadNewVersion(artifact.script.id, Buffer.from('current telemetry'));
const current = uploadNewVersion(
artifact.script.id,
Buffer.from('current telemetry'),
undefined,
'1.0.1'
);
db()
.prepare('UPDATE scripts SET current_version_id = ? WHERE id = ?')
.run(current.id, artifact.script.id);