disable blue-green deployment in test environment
This commit is contained in:
@@ -90,13 +90,12 @@ test('production single-service pipeline dispatches the blue-green executor', as
|
||||
assert.match(deploy, /if \[ "\$DEPLOY_ENV" = "production" \]/)
|
||||
assert.match(deploy, /run_ssh sh "\$REMOTE_DIR\/\$REMOTE_BLUE_GREEN_NAME"/)
|
||||
assert.match(deploy, /TARGET_IS_LOCAL[\s\S]*?deploy-blue-green-service\.sh/)
|
||||
assert.match(batch, /if \[ "\$DEPLOY_ENV" = "test" \] \|\| \[ "\$DEPLOY_ENV" = "production" \][\s\S]*?deploy-blue-green-service\.sh/)
|
||||
assert.match(batch, /sh deploy\/scripts\/deploy-blue-green-service\.sh/)
|
||||
})
|
||||
|
||||
test('test business services use blue-green while test gateways retain their fixed entry ports', async () => {
|
||||
test('test environment uses single-slot compose updates', async () => {
|
||||
const deploy = await read('deploy/scripts/deploy-built-service.sh')
|
||||
const batch = await read('deploy/scripts/deploy-services.sh')
|
||||
assert.match(deploy, /\[ "\$DEPLOY_ENV" = "test" \][\s\S]*?\[ "\$SERVICE" != "gateway" \]/)
|
||||
assert.match(batch, /\[ "\$DEPLOY_ENV" = "test" \] \|\| \[ "\$DEPLOY_ENV" = "production" \]/)
|
||||
assert.match(batch, /\[ "\$service" = gateway \] \|\| \[ "\$service" = gateway-overseas \]/)
|
||||
assert.doesNotMatch(deploy, /if \[ "\$DEPLOY_ENV" = "test" \] \\\n\s*\|\|[\s\S]*?deploy-blue-green-service\.sh/)
|
||||
assert.match(batch, /if \[ "\$DEPLOY_ENV" = test \]; then[\s\S]*?up -d --no-deps --pull never "\$service"/)
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user