mirror of
https://github.com/Shik3i/KoalaSync.git
synced 2026-08-29 03:57:09 +00:00
test: close release review gaps
This commit is contained in:
+1
-1
@@ -22,7 +22,7 @@ Please note that by participating in this project, you agree to abide by our [Co
|
|||||||
|
|
||||||
### Prerequisites
|
### Prerequisites
|
||||||
|
|
||||||
- **Node.js** v20.9+
|
- **Node.js** v20.19+
|
||||||
- **Docker** (for local relay server testing)
|
- **Docker** (for local relay server testing)
|
||||||
|
|
||||||
### Quick Start
|
### Quick Start
|
||||||
|
|||||||
+1
-1
@@ -104,7 +104,7 @@ creates a draft release, publishes and smoke-tests the relay image, and only
|
|||||||
afterwards makes the GitHub Release public. The published-asset gate runs:
|
afterwards makes the GitHub Release public. The published-asset gate runs:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
node scripts/verify-published-release.mjs v3.1.4 --repo Shik3i/KoalaSync
|
node scripts/verify-published-release.mjs vMAJOR.MINOR.PATCH --repo Shik3i/KoalaSync
|
||||||
```
|
```
|
||||||
|
|
||||||
The verifier requires the exact three release assets, validates SHA-256 hashes,
|
The verifier requires the exact three release assets, validates SHA-256 hashes,
|
||||||
|
|||||||
@@ -37,7 +37,10 @@ export async function startRelay(port) {
|
|||||||
throw new Error(`relay exited with ${child.exitCode}: ${output.join('')}`);
|
throw new Error(`relay exited with ${child.exitCode}: ${output.join('')}`);
|
||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
const response = await fetch(`http://127.0.0.1:${port}/health`);
|
const remainingMs = Math.max(1, deadline - Date.now());
|
||||||
|
const response = await fetch(`http://127.0.0.1:${port}/health`, {
|
||||||
|
signal: globalThis.AbortSignal.timeout(Math.min(1000, remainingMs))
|
||||||
|
});
|
||||||
if (response.ok) return { child, output };
|
if (response.ok) return { child, output };
|
||||||
} catch (_error) {
|
} catch (_error) {
|
||||||
// Relay is still starting.
|
// Relay is still starting.
|
||||||
|
|||||||
@@ -51,9 +51,10 @@ async function connect(context, extensionId, { relayUrl, roomId, username }) {
|
|||||||
test('@race synchronizes two packed clients across relay and service-worker restarts', async ({ context, extensionId, baseURL }) => {
|
test('@race synchronizes two packed clients across relay and service-worker restarts', async ({ context, extensionId, baseURL }) => {
|
||||||
test.setTimeout(120000);
|
test.setTimeout(120000);
|
||||||
const second = await launchExtensionContext();
|
const second = await launchExtensionContext();
|
||||||
const port = await reservePort();
|
let relay = null;
|
||||||
let relay = await startRelay(port);
|
|
||||||
try {
|
try {
|
||||||
|
const port = await reservePort();
|
||||||
|
relay = await startRelay(port);
|
||||||
const firstUrl = `${baseURL}/pages/simple-player.html?client=first`;
|
const firstUrl = `${baseURL}/pages/simple-player.html?client=first`;
|
||||||
const secondUrl = `${baseURL}/pages/simple-player.html?client=second`;
|
const secondUrl = `${baseURL}/pages/simple-player.html?client=second`;
|
||||||
const firstPage = await context.newPage();
|
const firstPage = await context.newPage();
|
||||||
|
|||||||
Reference in New Issue
Block a user