ci: stabilize macOS release verification
This commit is contained in:
@@ -16,10 +16,10 @@ jobs:
|
|||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Check out source
|
- name: Check out source
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v5
|
||||||
|
|
||||||
- name: Set up Node.js
|
- name: Set up Node.js
|
||||||
uses: actions/setup-node@v4
|
uses: actions/setup-node@v5
|
||||||
with:
|
with:
|
||||||
node-version: 22
|
node-version: 22
|
||||||
cache: npm
|
cache: npm
|
||||||
|
|||||||
@@ -23,10 +23,10 @@ jobs:
|
|||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Check out source
|
- name: Check out source
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v5
|
||||||
|
|
||||||
- name: Set up Node.js
|
- name: Set up Node.js
|
||||||
uses: actions/setup-node@v4
|
uses: actions/setup-node@v5
|
||||||
with:
|
with:
|
||||||
node-version: 22
|
node-version: 22
|
||||||
cache: npm
|
cache: npm
|
||||||
@@ -92,4 +92,3 @@ jobs:
|
|||||||
dist/*.yml
|
dist/*.yml
|
||||||
dist/SHA256SUMS-macos.txt
|
dist/SHA256SUMS-macos.txt
|
||||||
dist/module-catalog/*.pac
|
dist/module-catalog/*.pac
|
||||||
|
|
||||||
|
|||||||
@@ -13,8 +13,8 @@ jobs:
|
|||||||
php-releases:
|
php-releases:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v5
|
||||||
- uses: actions/setup-node@v4
|
- uses: actions/setup-node@v5
|
||||||
with:
|
with:
|
||||||
node-version: 22
|
node-version: 22
|
||||||
- name: Check official PHP releases
|
- name: Check official PHP releases
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ describe('native process supervisor', () => {
|
|||||||
command: process.execPath,
|
command: process.execPath,
|
||||||
args: [
|
args: [
|
||||||
'-e',
|
'-e',
|
||||||
`const s=require('net').createServer(c=>c.end('ok'));s.listen(${port},'127.0.0.1');console.log('ready')`
|
`const net=require('net');const s=net.createServer(c=>c.end('ok'));s.on('error',e=>{console.error(e);process.exit(1)});s.listen(${port},'127.0.0.1',()=>console.log('ready'));setInterval(()=>{},1000)`
|
||||||
],
|
],
|
||||||
cwd: root,
|
cwd: root,
|
||||||
logPath: join(root, 'service.log'),
|
logPath: join(root, 'service.log'),
|
||||||
@@ -22,12 +22,15 @@ describe('native process supervisor', () => {
|
|||||||
ready: { port, timeoutMs: 5000 }
|
ready: { port, timeoutMs: 5000 }
|
||||||
}
|
}
|
||||||
const supervisor = new NativeProcessSupervisor()
|
const supervisor = new NativeProcessSupervisor()
|
||||||
|
try {
|
||||||
const state = await supervisor.start(spec)
|
const state = await supervisor.start(spec)
|
||||||
expect(state.status).toBe('running')
|
expect(state.status).toBe('running')
|
||||||
expect(await supervisor.status(spec)).toBe('running')
|
expect(await supervisor.status(spec)).toBe('running')
|
||||||
await new Promise((resolve) => setTimeout(resolve, 50))
|
await new Promise((resolve) => setTimeout(resolve, 50))
|
||||||
expect(await readFile(spec.logPath, 'utf8')).toContain('ready')
|
expect(await readFile(spec.logPath, 'utf8')).toContain('ready')
|
||||||
|
} finally {
|
||||||
await supervisor.stop(spec)
|
await supervisor.stop(spec)
|
||||||
|
}
|
||||||
expect(await supervisor.status(spec)).toBe('stopped')
|
expect(await supervisor.status(spec)).toBe('stopped')
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user