refactor(core): Make instance role clearer (no-changelog) (#10188)

This commit is contained in:
Iván Ovejero
2024-07-30 10:20:21 +02:00
committed by GitHub
parent 47c7904028
commit 99dc56c7a1
9 changed files with 24 additions and 29 deletions

View File

@@ -146,7 +146,7 @@ describe('Orchestration Service', () => {
describe('shouldAddWebhooks', () => {
beforeEach(() => {
config.set('multiMainSetup.instanceType', 'leader');
config.set('instanceRole', 'leader');
});
test('should return true for init', () => {
// We want to ensure that webhooks are populated on init
@@ -169,7 +169,7 @@ describe('Orchestration Service', () => {
});
test('should return false for update or activate when not leader', () => {
config.set('multiMainSetup.instanceType', 'follower');
config.set('instanceRole', 'follower');
const modes = ['update', 'activate'] as WorkflowActivateMode[];
for (const mode of modes) {
const result = os.shouldAddWebhooks(mode);