Use database fleet registry and gate RCON polling on container readiness
This commit is contained in:
@@ -4,6 +4,8 @@ import { extractUdpPort, extractContainerState } from '../../src/lib/server/inte
|
||||
describe('container readiness', () => {
|
||||
it.each(['starting', 'unhealthy'])('does not accept a running container whose health is %s', (health) => {
|
||||
expect(extractContainerState({ State: { Status: 'running', Running: true, Health: { Status: health } } })).toBe(health);
|
||||
expect(extractContainerState({ state: 'running', health })).toBe(health);
|
||||
expect(extractContainerState({ state: 'running', health: { status: health } })).toBe(health);
|
||||
});
|
||||
it('accepts healthy running containers and preserves stopped states', () => {
|
||||
expect(extractContainerState({ State: { Status: 'running', Running: true, Health: { Status: 'healthy' } } })).toBe('running');
|
||||
|
||||
Reference in New Issue
Block a user