From baec6b80383bfa91b32a2e6b85e650a08ec1c5f8 Mon Sep 17 00:00:00 2001 From: gomarcopololead Date: Sat, 4 Jun 2022 00:04:13 +0800 Subject: [PATCH 1/4] feat: local provider scheduled command adapter unit test --- .../src/library/scheduled-adapter.ts | 2 +- .../test/helpers/scheduled-helper.ts | 11 ++++ .../test/library/scheduled-adapter.test.ts | 65 +++++++++++++++++++ 3 files changed, 77 insertions(+), 1 deletion(-) create mode 100644 packages/framework-provider-local/test/helpers/scheduled-helper.ts create mode 100644 packages/framework-provider-local/test/library/scheduled-adapter.test.ts diff --git a/packages/framework-provider-local/src/library/scheduled-adapter.ts b/packages/framework-provider-local/src/library/scheduled-adapter.ts index b6df7700c..329203baf 100644 --- a/packages/framework-provider-local/src/library/scheduled-adapter.ts +++ b/packages/framework-provider-local/src/library/scheduled-adapter.ts @@ -1,7 +1,7 @@ import { BoosterConfig, ScheduledCommandEnvelope, UUID } from '@boostercloud/framework-types' import { getLogger } from '@boostercloud/framework-common-helpers' -interface LocalScheduleCommandEnvelope { +export interface LocalScheduleCommandEnvelope { typeName: string } diff --git a/packages/framework-provider-local/test/helpers/scheduled-helper.ts b/packages/framework-provider-local/test/helpers/scheduled-helper.ts new file mode 100644 index 000000000..585829a43 --- /dev/null +++ b/packages/framework-provider-local/test/helpers/scheduled-helper.ts @@ -0,0 +1,11 @@ +import { random } from 'faker' + +interface LocalScheduleCommandEnvelope { + typeName: string +} + +export function createMockLocalScheduleCommandEnvelope(): Partial { + return { + typeName: random.word() + } +} diff --git a/packages/framework-provider-local/test/library/scheduled-adapter.test.ts b/packages/framework-provider-local/test/library/scheduled-adapter.test.ts new file mode 100644 index 000000000..c4831975f --- /dev/null +++ b/packages/framework-provider-local/test/library/scheduled-adapter.test.ts @@ -0,0 +1,65 @@ +/* eslint-disable @typescript-eslint/no-explicit-any */ +import { SinonStub, stub, replace, restore } from 'sinon' +import { rawScheduledInputToEnvelope, LocalScheduleCommandEnvelope } from '../../src/library/scheduled-adapter' +import { createMockLocalScheduleCommandEnvelope } from '../helpers/scheduled-helper' +import { UUID } from '@boostercloud/framework-types' +import { expect } from '../expect' +import { random } from 'faker' + +describe('Local provider scheduled-adapter', () => { + describe('rawScheduledInputToEnvelope', () => { + let mockScheduledEnvelop: Partial + let mockEmptyScheduledEnvelop: Partial + let mockUuid: string + + let debugStub: SinonStub + let generateStub: SinonStub + + let logger: any + + beforeEach(() => { + mockUuid = random.uuid() + + mockScheduledEnvelop = createMockLocalScheduleCommandEnvelope() + mockEmptyScheduledEnvelop = {} + + debugStub = stub() + generateStub = stub().returns(mockUuid) + + logger = { + debug: debugStub, + } + replace(UUID, 'generate', generateStub) + }) + + afterEach(() => { + restore() + }) + + it('should call logger.debug', async () => { + await rawScheduledInputToEnvelope(mockScheduledEnvelop, logger) + + expect(debugStub).to.have.been.calledOnceWith( + 'Received LocalScheduleCommand request: ', + mockScheduledEnvelop + ) + }) + + it('should thrown an exception for empty typeName', async () => { + const error = new Error( + `typeName is not defined or empty, scheduled command envelope should have the structure {typeName: string }, but you gave ${JSON.stringify( + mockEmptyScheduledEnvelop + )}` + ) + expect(rawScheduledInputToEnvelope(mockEmptyScheduledEnvelop, logger)).to.be.rejectedWith(error) + }) + + it('should generate expected envelop', async () => { + const result = await rawScheduledInputToEnvelope(mockScheduledEnvelop, logger) + expect(result).to.be.deep.equal({ + requestID: mockUuid, + typeName: mockScheduledEnvelop.typeName + }) + }) + }) +}) From 47c99bd1864cd1d881cb548c425bc2f32c2c0b4e Mon Sep 17 00:00:00 2001 From: gomarcopololead Date: Mon, 6 Jun 2022 15:24:04 +0800 Subject: [PATCH 2/4] feat: unit test for local provider infrastructure scheulder --- .../src/scheduler.ts | 30 +++++-- .../test/scheduler.test.ts | 84 +++++++++++++++++++ 2 files changed, 106 insertions(+), 8 deletions(-) create mode 100644 packages/framework-provider-local-infrastructure/test/scheduler.test.ts diff --git a/packages/framework-provider-local-infrastructure/src/scheduler.ts b/packages/framework-provider-local-infrastructure/src/scheduler.ts index fa9b37bb4..2335e653d 100644 --- a/packages/framework-provider-local-infrastructure/src/scheduler.ts +++ b/packages/framework-provider-local-infrastructure/src/scheduler.ts @@ -6,24 +6,38 @@ interface ScheduledCommandInfo { metadata: ScheduledCommandMetadata } -export function configureScheduler(config: BoosterConfig, userProject: any): void { +export function configureScheduler(config: BoosterConfig, userProject: any): scheduler.Job[] { const triggerScheduleCommand = userProject['boosterTriggerScheduledCommand'] + const cronJobs: scheduler.Job[] = [] Object.keys(config.scheduledCommandHandlers) .map((scheduledCommandName) => buildScheduledCommandInfo(config, scheduledCommandName)) .filter((scheduledCommandInfo) => scheduledCommandInfo.metadata.scheduledOn) .forEach((scheduledCommandInfo) => { - scheduler.scheduleJob(scheduledCommandInfo.name, createCronExpression(scheduledCommandInfo.metadata), () => { - triggerScheduleCommand({ typeName: scheduledCommandInfo.name }) - }) + const cronJob = scheduler.scheduleJob( + scheduledCommandInfo.name, + createCronExpression(scheduledCommandInfo.metadata), + () => { + triggerScheduleCommand({ typeName: scheduledCommandInfo.name }) + } + ) + cronJobs.push(cronJob) }) + return cronJobs } -function createCronExpression(scheduledCommandMetadata: ScheduledCommandMetadata): string { - const { minute = '*', hour = '*', day = '*', month = '*', weekDay = '*' } = scheduledCommandMetadata.scheduledOn - return `${minute} ${hour} ${day} ${month} ${weekDay}` +export function createCronExpression(scheduledCommandMetadata: ScheduledCommandMetadata): string { + const { + second = '*', + minute = '*', + hour = '*', + day = '*', + month = '*', + weekDay = '*', + } = scheduledCommandMetadata.scheduledOn + return `${second} ${minute} ${hour} ${day} ${month} ${weekDay}` } -function buildScheduledCommandInfo(config: BoosterConfig, scheduledCommandName: string): ScheduledCommandInfo { +export function buildScheduledCommandInfo(config: BoosterConfig, scheduledCommandName: string): ScheduledCommandInfo { return { name: scheduledCommandName, metadata: config.scheduledCommandHandlers[scheduledCommandName], diff --git a/packages/framework-provider-local-infrastructure/test/scheduler.test.ts b/packages/framework-provider-local-infrastructure/test/scheduler.test.ts new file mode 100644 index 000000000..8a95f6ae6 --- /dev/null +++ b/packages/framework-provider-local-infrastructure/test/scheduler.test.ts @@ -0,0 +1,84 @@ +import { BoosterConfig } from '@boostercloud/framework-types' +import { restore, SinonStub, SinonStubbedInstance, createStubInstance, replace, stub, useFakeTimers } from 'sinon' +import { configureScheduler, createCronExpression, buildScheduledCommandInfo } from '../src/scheduler' +import { expect } from './expect' +import { describe } from 'mocha' +import { random } from 'faker' + +declare class UserProject { + constructor() + boosterTriggerScheduledCommand: (rawRequest: unknown) => void +} +describe('Local Scheduler', () => { + let mockUserProjectStub: SinonStubbedInstance + let mockScheduledCommand: any + let mockConfig: BoosterConfig + let mockScheduledCommandName: string + let queryStub: SinonStub + let clock: any + + beforeEach(() => { + class CheckCart { + public static async handle(): Promise { + console.log('handle') + } + } + class UserProject { + boosterTriggerScheduledCommand(rawRequest: unknown): void { + console.log('rawRequest: ', rawRequest) + } + } + + clock = useFakeTimers() + + mockScheduledCommandName = random.word() + queryStub = stub() + + mockUserProjectStub = createStubInstance(UserProject) + replace(mockUserProjectStub, 'boosterTriggerScheduledCommand', queryStub as any) + + mockConfig = buildConfig() + mockConfig.scheduledCommandHandlers[mockScheduledCommandName] = { + class: CheckCart, + scheduledOn: {}, + } + + mockScheduledCommand = buildScheduledCommandInfo(mockConfig, mockScheduledCommandName) + }) + + afterEach(() => { + restore() + }) + + describe('buildScheduledCommandInfo', () => { + it('should return expected scheduled command info', async () => { + const result = await buildScheduledCommandInfo(mockConfig, mockScheduledCommandName) + expect(result).to.be.deep.equal({ + name: mockScheduledCommandName, + metadata: mockConfig.scheduledCommandHandlers[mockScheduledCommandName], + }) + }) + }) + + describe('createCronExpression', () => { + it('should return expected cron expression', async () => { + const result = await createCronExpression(mockScheduledCommand.metadata) + expect(result).to.be.equal('* * * * * *') + }) + }) + + describe('configureScheduler', () => { + it('should call scedule job', async () => { + const results = configureScheduler(mockConfig, mockUserProjectStub) + clock.tick(3250) + setTimeout(() => { + results.forEach((result) => result.cancel()) + }, 3250) + expect(queryStub).to.have.callCount(3) + }) + }) + + function buildConfig(): BoosterConfig { + return new BoosterConfig('test') + } +}) From 0b9e6a29b7534170f9c3416d74c925f3a9c90a18 Mon Sep 17 00:00:00 2001 From: gomarcopololead Date: Tue, 7 Jun 2022 18:59:21 +0800 Subject: [PATCH 3/4] chore: request changes from javiertoledo --- .../src/scheduler.ts | 19 ++----- .../test/scheduler.test.ts | 56 ++++++++++++------- 2 files changed, 43 insertions(+), 32 deletions(-) diff --git a/packages/framework-provider-local-infrastructure/src/scheduler.ts b/packages/framework-provider-local-infrastructure/src/scheduler.ts index 2335e653d..773d2ded8 100644 --- a/packages/framework-provider-local-infrastructure/src/scheduler.ts +++ b/packages/framework-provider-local-infrastructure/src/scheduler.ts @@ -6,26 +6,19 @@ interface ScheduledCommandInfo { metadata: ScheduledCommandMetadata } -export function configureScheduler(config: BoosterConfig, userProject: any): scheduler.Job[] { +export function configureScheduler(config: BoosterConfig, userProject: any): void { const triggerScheduleCommand = userProject['boosterTriggerScheduledCommand'] - const cronJobs: scheduler.Job[] = [] Object.keys(config.scheduledCommandHandlers) .map((scheduledCommandName) => buildScheduledCommandInfo(config, scheduledCommandName)) .filter((scheduledCommandInfo) => scheduledCommandInfo.metadata.scheduledOn) .forEach((scheduledCommandInfo) => { - const cronJob = scheduler.scheduleJob( - scheduledCommandInfo.name, - createCronExpression(scheduledCommandInfo.metadata), - () => { - triggerScheduleCommand({ typeName: scheduledCommandInfo.name }) - } - ) - cronJobs.push(cronJob) + scheduler.scheduleJob(scheduledCommandInfo.name, createCronExpression(scheduledCommandInfo.metadata), () => { + triggerScheduleCommand({ typeName: scheduledCommandInfo.name }) + }) }) - return cronJobs } -export function createCronExpression(scheduledCommandMetadata: ScheduledCommandMetadata): string { +function createCronExpression(scheduledCommandMetadata: ScheduledCommandMetadata): string { const { second = '*', minute = '*', @@ -37,7 +30,7 @@ export function createCronExpression(scheduledCommandMetadata: ScheduledCommandM return `${second} ${minute} ${hour} ${day} ${month} ${weekDay}` } -export function buildScheduledCommandInfo(config: BoosterConfig, scheduledCommandName: string): ScheduledCommandInfo { +function buildScheduledCommandInfo(config: BoosterConfig, scheduledCommandName: string): ScheduledCommandInfo { return { name: scheduledCommandName, metadata: config.scheduledCommandHandlers[scheduledCommandName], diff --git a/packages/framework-provider-local-infrastructure/test/scheduler.test.ts b/packages/framework-provider-local-infrastructure/test/scheduler.test.ts index 8a95f6ae6..539b778af 100644 --- a/packages/framework-provider-local-infrastructure/test/scheduler.test.ts +++ b/packages/framework-provider-local-infrastructure/test/scheduler.test.ts @@ -1,21 +1,27 @@ import { BoosterConfig } from '@boostercloud/framework-types' -import { restore, SinonStub, SinonStubbedInstance, createStubInstance, replace, stub, useFakeTimers } from 'sinon' -import { configureScheduler, createCronExpression, buildScheduledCommandInfo } from '../src/scheduler' +import { restore, SinonStubbedInstance, createStubInstance, replace, fake } from 'sinon' +import { configureScheduler } from '../src/scheduler' import { expect } from './expect' import { describe } from 'mocha' import { random } from 'faker' +import * as scheduler from 'node-schedule' +const rewire = require('rewire') +const schedule = rewire('../src/scheduler') +const createCronExpression = schedule.__get__('createCronExpression') +const buildScheduledCommandInfo = schedule.__get__('buildScheduledCommandInfo') +interface ScheduledCommandInfo { + typeName: string +} declare class UserProject { constructor() boosterTriggerScheduledCommand: (rawRequest: unknown) => void } + describe('Local Scheduler', () => { let mockUserProjectStub: SinonStubbedInstance - let mockScheduledCommand: any let mockConfig: BoosterConfig let mockScheduledCommandName: string - let queryStub: SinonStub - let clock: any beforeEach(() => { class CheckCart { @@ -29,21 +35,15 @@ describe('Local Scheduler', () => { } } - clock = useFakeTimers() - mockScheduledCommandName = random.word() - queryStub = stub() mockUserProjectStub = createStubInstance(UserProject) - replace(mockUserProjectStub, 'boosterTriggerScheduledCommand', queryStub as any) mockConfig = buildConfig() mockConfig.scheduledCommandHandlers[mockScheduledCommandName] = { class: CheckCart, scheduledOn: {}, } - - mockScheduledCommand = buildScheduledCommandInfo(mockConfig, mockScheduledCommandName) }) afterEach(() => { @@ -61,20 +61,38 @@ describe('Local Scheduler', () => { }) describe('createCronExpression', () => { - it('should return expected cron expression', async () => { - const result = await createCronExpression(mockScheduledCommand.metadata) + it('should return default cron expression', async () => { + const result = await createCronExpression({ scheduledOn: {} }) expect(result).to.be.equal('* * * * * *') }) + + it('should return expected cron expression', async () => { + const result = await createCronExpression({ + scheduledOn: { + minute: '30', + hour: '14', + weekDay: '0', + }, + }) + expect(result).to.be.equal('* 30 14 * * 0') + }) }) describe('configureScheduler', () => { it('should call scedule job', async () => { - const results = configureScheduler(mockConfig, mockUserProjectStub) - clock.tick(3250) - setTimeout(() => { - results.forEach((result) => result.cancel()) - }, 3250) - expect(queryStub).to.have.callCount(3) + const fakeScheduleJob = fake((name: string, cronExpression: string, scheduledFunction: () => void) => { + scheduledFunction() + }) + const fakeTriggerScheduleCommand = fake((command: ScheduledCommandInfo) => {}) + replace(scheduler, 'scheduleJob', fakeScheduleJob) + replace(mockUserProjectStub, 'boosterTriggerScheduledCommand', fakeTriggerScheduleCommand as any) + + configureScheduler(mockConfig, mockUserProjectStub) + + expect(scheduler.scheduleJob).to.have.been.calledWith(mockScheduledCommandName, '* * * * * *') + expect(mockUserProjectStub.boosterTriggerScheduledCommand).to.have.been.calledWith({ + typeName: mockScheduledCommandName, + }) }) }) From f44c0073c3fcafe0c956e95064df5c1805c36a08 Mon Sep 17 00:00:00 2001 From: Javier Toledo Date: Tue, 28 Feb 2023 23:13:11 +0000 Subject: [PATCH 4/4] Fixed tests and lint errors --- ...-schedule-unit-tests_2023-02-28-23-16.json | 10 + common/config/rush/pnpm-lock.yaml | 261 +++++++++--------- .../test/helpers/scheduled-helper.ts | 2 +- .../test/library/scheduled-adapter.test.ts | 40 ++- packages/framework-types/src/schedule.ts | 1 + 5 files changed, 156 insertions(+), 158 deletions(-) create mode 100644 common/changes/@boostercloud/framework-core/feat-local-schedule-unit-tests_2023-02-28-23-16.json diff --git a/common/changes/@boostercloud/framework-core/feat-local-schedule-unit-tests_2023-02-28-23-16.json b/common/changes/@boostercloud/framework-core/feat-local-schedule-unit-tests_2023-02-28-23-16.json new file mode 100644 index 000000000..eeb00b19d --- /dev/null +++ b/common/changes/@boostercloud/framework-core/feat-local-schedule-unit-tests_2023-02-28-23-16.json @@ -0,0 +1,10 @@ +{ + "changes": [ + { + "packageName": "@boostercloud/framework-core", + "comment": "Added tests for local scheduled commands", + "type": "patch" + } + ], + "packageName": "@boostercloud/framework-core" +} \ No newline at end of file diff --git a/common/config/rush/pnpm-lock.yaml b/common/config/rush/pnpm-lock.yaml index b0f68e4e9..997bf6822 100644 --- a/common/config/rush/pnpm-lock.yaml +++ b/common/config/rush/pnpm-lock.yaml @@ -7,8 +7,8 @@ importers: ../../packages/application-tester: specifiers: - '@boostercloud/eslint-config': workspace:^1.6.2 - '@boostercloud/framework-types': workspace:^1.6.2 + '@boostercloud/eslint-config': workspace:^1.7.0 + '@boostercloud/framework-types': workspace:^1.7.0 '@effect-ts/core': ^0.60.4 '@types/jsonwebtoken': ^8.5.8 '@types/node': 16.11.7 @@ -78,10 +78,10 @@ importers: ../../packages/cli: specifiers: - '@boostercloud/application-tester': workspace:^1.6.2 - '@boostercloud/eslint-config': workspace:^1.6.2 - '@boostercloud/framework-core': workspace:^1.6.2 - '@boostercloud/framework-types': workspace:^1.6.2 + '@boostercloud/application-tester': workspace:^1.7.0 + '@boostercloud/eslint-config': workspace:^1.7.0 + '@boostercloud/framework-core': workspace:^1.7.0 + '@boostercloud/framework-types': workspace:^1.7.0 '@effect-ts/core': ^0.60.4 '@oclif/command': ^1.8 '@oclif/config': ^1.18 @@ -197,8 +197,8 @@ importers: ../../packages/framework-common-helpers: specifiers: - '@boostercloud/eslint-config': workspace:^1.6.2 - '@boostercloud/framework-types': workspace:^1.6.2 + '@boostercloud/eslint-config': workspace:^1.7.0 + '@boostercloud/framework-types': workspace:^1.7.0 '@effect-ts/core': ^0.60.4 '@types/chai': 4.2.18 '@types/chai-as-promised': 7.1.4 @@ -266,10 +266,10 @@ importers: ../../packages/framework-core: specifiers: - '@boostercloud/eslint-config': workspace:^1.6.2 - '@boostercloud/framework-common-helpers': workspace:^1.6.2 - '@boostercloud/framework-types': workspace:^1.6.2 - '@boostercloud/metadata-booster': workspace:^1.6.2 + '@boostercloud/eslint-config': workspace:^1.7.0 + '@boostercloud/framework-common-helpers': workspace:^1.7.0 + '@boostercloud/framework-types': workspace:^1.7.0 + '@boostercloud/metadata-booster': workspace:^1.7.0 '@effect-ts/core': ^0.60.4 '@types/chai': 4.2.18 '@types/chai-as-promised': 7.1.4 @@ -365,21 +365,21 @@ importers: ../../packages/framework-integration-tests: specifiers: - '@boostercloud/application-tester': workspace:^1.6.2 - '@boostercloud/cli': workspace:^1.6.2 - '@boostercloud/eslint-config': workspace:^1.6.2 - '@boostercloud/framework-common-helpers': workspace:^1.6.2 - '@boostercloud/framework-core': workspace:^1.6.2 - '@boostercloud/framework-provider-aws': workspace:^1.6.2 - '@boostercloud/framework-provider-aws-infrastructure': workspace:^1.6.2 - '@boostercloud/framework-provider-azure': workspace:^1.6.2 - '@boostercloud/framework-provider-azure-infrastructure': workspace:^1.6.2 - '@boostercloud/framework-provider-kubernetes': workspace:^1.6.2 - '@boostercloud/framework-provider-kubernetes-infrastructure': workspace:^1.6.2 - '@boostercloud/framework-provider-local': workspace:^1.6.2 - '@boostercloud/framework-provider-local-infrastructure': workspace:^1.6.2 - '@boostercloud/framework-types': workspace:^1.6.2 - '@boostercloud/metadata-booster': workspace:^1.6.2 + '@boostercloud/application-tester': workspace:^1.7.0 + '@boostercloud/cli': workspace:^1.7.0 + '@boostercloud/eslint-config': workspace:^1.7.0 + '@boostercloud/framework-common-helpers': workspace:^1.7.0 + '@boostercloud/framework-core': workspace:^1.7.0 + '@boostercloud/framework-provider-aws': workspace:^1.7.0 + '@boostercloud/framework-provider-aws-infrastructure': workspace:^1.7.0 + '@boostercloud/framework-provider-azure': workspace:^1.7.0 + '@boostercloud/framework-provider-azure-infrastructure': workspace:^1.7.0 + '@boostercloud/framework-provider-kubernetes': workspace:^1.7.0 + '@boostercloud/framework-provider-kubernetes-infrastructure': workspace:^1.7.0 + '@boostercloud/framework-provider-local': workspace:^1.7.0 + '@boostercloud/framework-provider-local-infrastructure': workspace:^1.7.0 + '@boostercloud/framework-types': workspace:^1.7.0 + '@boostercloud/metadata-booster': workspace:^1.7.0 '@effect-ts/core': ^0.60.4 '@kubernetes/client-node': ^0.17.0 '@types/aws-lambda': 8.10.48 @@ -520,9 +520,9 @@ importers: ../../packages/framework-provider-aws: specifiers: - '@boostercloud/eslint-config': workspace:^1.6.2 - '@boostercloud/framework-common-helpers': workspace:^1.6.2 - '@boostercloud/framework-types': workspace:^1.6.2 + '@boostercloud/eslint-config': workspace:^1.7.0 + '@boostercloud/framework-common-helpers': workspace:^1.7.0 + '@boostercloud/framework-types': workspace:^1.7.0 '@effect-ts/core': ^0.60.4 '@types/aws-lambda': 8.10.48 '@types/chai': 4.2.18 @@ -616,10 +616,10 @@ importers: '@aws-cdk/core': ^1.170.0 '@aws-cdk/custom-resources': ^1.170.0 '@aws-cdk/cx-api': ^1.170.0 - '@boostercloud/eslint-config': workspace:^1.6.2 - '@boostercloud/framework-common-helpers': workspace:^1.6.2 - '@boostercloud/framework-provider-aws': workspace:^1.6.2 - '@boostercloud/framework-types': workspace:^1.6.2 + '@boostercloud/eslint-config': workspace:^1.7.0 + '@boostercloud/framework-common-helpers': workspace:^1.7.0 + '@boostercloud/framework-provider-aws': workspace:^1.7.0 + '@boostercloud/framework-types': workspace:^1.7.0 '@effect-ts/core': ^0.60.4 '@types/archiver': 5.1.0 '@types/aws-lambda': 8.10.48 @@ -664,20 +664,20 @@ importers: dependencies: '@aws-cdk/assets': 1.193.0_5cocr36pjfvlto7s7kbof5rxfm '@aws-cdk/aws-apigateway': 1.193.0_upk4xvmulko4zwrdpwfmngkhia - '@aws-cdk/aws-apigatewayv2': 1.193.0_gqcd7osjtxd6yzxf76nth7r3mu - '@aws-cdk/aws-cloudfront': 1.193.0_gqcd7osjtxd6yzxf76nth7r3mu + '@aws-cdk/aws-apigatewayv2': 1.193.0_5ctpspowm3ljnb7k7tab7mknia + '@aws-cdk/aws-cloudfront': 1.193.0_5ctpspowm3ljnb7k7tab7mknia '@aws-cdk/aws-dynamodb': 1.193.0_hw4y3fnmtspigwybrnhagitzgi '@aws-cdk/aws-events': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm '@aws-cdk/aws-events-targets': 1.193.0_i2hxngstmfsj7v6v6mmxqdzlum '@aws-cdk/aws-iam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq '@aws-cdk/aws-lambda': 1.193.0_hjndse4uvjoh2z652h4gibqbfa - '@aws-cdk/aws-lambda-event-sources': 1.193.0_qg64zmashm7t2rdsmtncvmznfa + '@aws-cdk/aws-lambda-event-sources': 1.193.0_u3lhvz6x4k55rd3cwzxax7sbuy '@aws-cdk/aws-logs': 1.193.0_fl7hneqefdk7a7rv75sucgtmwm '@aws-cdk/aws-s3': 1.193.0_s6ljqdn2iypvkcrzn7mbvz6gaq '@aws-cdk/aws-s3-deployment': 1.193.0_5t5t5ptyd7ju3r7nqri4oel4va '@aws-cdk/cloudformation-diff': 1.193.0 '@aws-cdk/core': 1.193.0_jfsf2uupw3z2wi6nn7gnreoyte - '@aws-cdk/custom-resources': 1.193.0_ld77ehigssy773vrtmey3cniuq + '@aws-cdk/custom-resources': 1.193.0_7v4p4u6jnphcil74xczvpzwlfy '@aws-cdk/cx-api': 1.193.0 '@boostercloud/framework-common-helpers': link:../framework-common-helpers '@boostercloud/framework-provider-aws': link:../framework-provider-aws @@ -731,9 +731,9 @@ importers: '@azure/cosmos': ^3.17.0 '@azure/functions': ^1.2.2 '@azure/identity': ~2.1.0 - '@boostercloud/eslint-config': workspace:^1.6.2 - '@boostercloud/framework-common-helpers': workspace:^1.6.2 - '@boostercloud/framework-types': workspace:^1.6.2 + '@boostercloud/eslint-config': workspace:^1.7.0 + '@boostercloud/framework-common-helpers': workspace:^1.7.0 + '@boostercloud/framework-types': workspace:^1.7.0 '@effect-ts/core': ^0.60.4 '@types/chai': 4.2.18 '@types/chai-as-promised': 7.1.4 @@ -803,11 +803,11 @@ importers: '@azure/arm-resources': ^5.0.1 '@azure/cosmos': ^3.17.0 '@azure/identity': ~2.1.0 - '@boostercloud/eslint-config': workspace:^1.6.2 - '@boostercloud/framework-common-helpers': workspace:^1.6.2 - '@boostercloud/framework-core': workspace:^1.6.2 - '@boostercloud/framework-provider-azure': workspace:^1.6.2 - '@boostercloud/framework-types': workspace:^1.6.2 + '@boostercloud/eslint-config': workspace:^1.7.0 + '@boostercloud/framework-common-helpers': workspace:^1.7.0 + '@boostercloud/framework-core': workspace:^1.7.0 + '@boostercloud/framework-provider-azure': workspace:^1.7.0 + '@boostercloud/framework-types': workspace:^1.7.0 '@cdktf/provider-azurerm': ^0.2.179 '@effect-ts/core': ^0.60.4 '@types/archiver': 5.1.0 @@ -912,9 +912,9 @@ importers: ../../packages/framework-provider-kubernetes: specifiers: - '@boostercloud/eslint-config': workspace:^1.6.2 - '@boostercloud/framework-common-helpers': workspace:^1.6.2 - '@boostercloud/framework-types': workspace:^1.6.2 + '@boostercloud/eslint-config': workspace:^1.7.0 + '@boostercloud/framework-common-helpers': workspace:^1.7.0 + '@boostercloud/framework-types': workspace:^1.7.0 '@effect-ts/core': ^0.60.4 '@types/body-parser': ~1.19.2 '@types/chai': 4.2.18 @@ -991,9 +991,9 @@ importers: ../../packages/framework-provider-kubernetes-infrastructure: specifiers: - '@boostercloud/eslint-config': workspace:^1.6.2 - '@boostercloud/framework-common-helpers': workspace:^1.6.2 - '@boostercloud/framework-types': workspace:^1.6.2 + '@boostercloud/eslint-config': workspace:^1.7.0 + '@boostercloud/framework-common-helpers': workspace:^1.7.0 + '@boostercloud/framework-types': workspace:^1.7.0 '@effect-ts/core': ^0.60.4 '@kubernetes/client-node': ^0.17.0 '@types/archiver': 5.1.0 @@ -1094,9 +1094,9 @@ importers: ../../packages/framework-provider-local: specifiers: - '@boostercloud/eslint-config': workspace:^1.6.2 - '@boostercloud/framework-common-helpers': workspace:^1.6.2 - '@boostercloud/framework-types': workspace:^1.6.2 + '@boostercloud/eslint-config': workspace:^1.7.0 + '@boostercloud/framework-common-helpers': workspace:^1.7.0 + '@boostercloud/framework-types': workspace:^1.7.0 '@effect-ts/core': ^0.60.4 '@types/chai': 4.2.18 '@types/chai-as-promised': 7.1.4 @@ -1171,10 +1171,10 @@ importers: ../../packages/framework-provider-local-infrastructure: specifiers: - '@boostercloud/eslint-config': workspace:^1.6.2 - '@boostercloud/framework-common-helpers': workspace:^1.6.2 - '@boostercloud/framework-provider-local': workspace:^1.6.2 - '@boostercloud/framework-types': workspace:^1.6.2 + '@boostercloud/eslint-config': workspace:^1.7.0 + '@boostercloud/framework-common-helpers': workspace:^1.7.0 + '@boostercloud/framework-provider-local': workspace:^1.7.0 + '@boostercloud/framework-types': workspace:^1.7.0 '@effect-ts/core': ^0.60.4 '@types/chai': 4.2.18 '@types/chai-as-promised': 7.1.4 @@ -1258,8 +1258,8 @@ importers: ../../packages/framework-types: specifiers: - '@boostercloud/eslint-config': workspace:^1.6.2 - '@boostercloud/metadata-booster': workspace:^1.6.2 + '@boostercloud/eslint-config': workspace:^1.7.0 + '@boostercloud/metadata-booster': workspace:^1.7.0 '@effect-ts/core': ^0.60.4 '@effect-ts/node': ~0.39.0 '@types/chai': 4.2.18 @@ -1325,7 +1325,7 @@ importers: ../../packages/metadata-booster: specifiers: - '@boostercloud/eslint-config': workspace:^1.6.2 + '@boostercloud/eslint-config': workspace:^1.7.0 '@effect-ts/core': ^0.60.4 '@types/node': 16.11.7 '@typescript-eslint/eslint-plugin': ^5.0.0 @@ -1443,8 +1443,8 @@ packages: '@aws-cdk/aws-certificatemanager': 1.193.0_j6i3cfn46lxtg3dfxtfr6gwjsi '@aws-cdk/aws-cloudwatch': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm '@aws-cdk/aws-cognito': 1.193.0_6tofvxpai7zkmpcugq5ucgdema - '@aws-cdk/aws-ec2': 1.193.0_aelxr2tctgck6ft5trqziwzmui - '@aws-cdk/aws-elasticloadbalancingv2': 1.193.0_gqcd7osjtxd6yzxf76nth7r3mu + '@aws-cdk/aws-ec2': 1.193.0_oyrygtfcc75tqlje6mdv4epydy + '@aws-cdk/aws-elasticloadbalancingv2': 1.193.0_dwclitksqmczbyyowpqfwws5du '@aws-cdk/aws-iam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq '@aws-cdk/aws-lambda': 1.193.0_hjndse4uvjoh2z652h4gibqbfa '@aws-cdk/aws-logs': 1.193.0_fl7hneqefdk7a7rv75sucgtmwm @@ -1460,7 +1460,7 @@ packages: - '@aws-cdk/custom-resources' dev: false - /@aws-cdk/aws-apigatewayv2/1.193.0_gqcd7osjtxd6yzxf76nth7r3mu: + /@aws-cdk/aws-apigatewayv2/1.193.0_5ctpspowm3ljnb7k7tab7mknia: resolution: {integrity: sha512-QQayQNAP3RhZVWOrJWmGzmdjHVtcj8dnUl+cR+0tN288LKFVNJyERmQhskWDvFDxA3yMBQdehDw1n2pk1eRJtA==} engines: {node: '>= 14.15.0'} peerDependencies: @@ -1471,13 +1471,12 @@ packages: dependencies: '@aws-cdk/aws-certificatemanager': 1.193.0_j6i3cfn46lxtg3dfxtfr6gwjsi '@aws-cdk/aws-cloudwatch': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm - '@aws-cdk/aws-ec2': 1.193.0_aelxr2tctgck6ft5trqziwzmui + '@aws-cdk/aws-ec2': 1.193.0_oyrygtfcc75tqlje6mdv4epydy '@aws-cdk/aws-iam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq '@aws-cdk/aws-s3': 1.193.0_s6ljqdn2iypvkcrzn7mbvz6gaq '@aws-cdk/core': 1.193.0_jfsf2uupw3z2wi6nn7gnreoyte constructs: 3.4.251 transitivePeerDependencies: - - '@aws-cdk/assets' - '@aws-cdk/aws-lambda' - '@aws-cdk/aws-logs' - '@aws-cdk/custom-resources' @@ -1526,7 +1525,7 @@ packages: '@aws-cdk/core': 1.193.0 constructs: ^3.3.69 dependencies: - '@aws-cdk/aws-autoscaling': 1.193.0_upk4xvmulko4zwrdpwfmngkhia + '@aws-cdk/aws-autoscaling': 1.193.0_l2gj7iq54jshudrxdpvnknsadu '@aws-cdk/aws-iam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq '@aws-cdk/aws-kms': 1.193.0_wv5he25vlfitynxjm2o4t3p5vu '@aws-cdk/aws-lambda': 1.193.0_hjndse4uvjoh2z652h4gibqbfa @@ -1537,7 +1536,7 @@ packages: constructs: 3.4.251 dev: false - /@aws-cdk/aws-autoscaling/1.193.0_upk4xvmulko4zwrdpwfmngkhia: + /@aws-cdk/aws-autoscaling/1.193.0_l2gj7iq54jshudrxdpvnknsadu: resolution: {integrity: sha512-po7E/VQPPPAEapDtuyZsLuak3k93w9EEm0uJoipveAfdRjRY3zl8xiGNouQlm5dd1Ip3jefB6Er0l2pbLA36bQ==} engines: {node: '>= 14.15.0'} peerDependencies: @@ -1547,15 +1546,14 @@ packages: dependencies: '@aws-cdk/aws-autoscaling-common': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm '@aws-cdk/aws-cloudwatch': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm - '@aws-cdk/aws-ec2': 1.193.0_aelxr2tctgck6ft5trqziwzmui + '@aws-cdk/aws-ec2': 1.193.0_oyrygtfcc75tqlje6mdv4epydy '@aws-cdk/aws-elasticloadbalancing': 1.193.0_6pqcupvooeqlpupvlzhdrord2u - '@aws-cdk/aws-elasticloadbalancingv2': 1.193.0_gqcd7osjtxd6yzxf76nth7r3mu + '@aws-cdk/aws-elasticloadbalancingv2': 1.193.0_dwclitksqmczbyyowpqfwws5du '@aws-cdk/aws-iam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq '@aws-cdk/aws-sns': 1.193.0_s6ljqdn2iypvkcrzn7mbvz6gaq '@aws-cdk/core': 1.193.0_jfsf2uupw3z2wi6nn7gnreoyte constructs: 3.4.251 transitivePeerDependencies: - - '@aws-cdk/assets' - '@aws-cdk/aws-events' - '@aws-cdk/aws-lambda' - '@aws-cdk/aws-logs' @@ -1608,7 +1606,7 @@ packages: - '@aws-cdk/aws-events' dev: false - /@aws-cdk/aws-cloudfront/1.193.0_gqcd7osjtxd6yzxf76nth7r3mu: + /@aws-cdk/aws-cloudfront/1.193.0_5ctpspowm3ljnb7k7tab7mknia: resolution: {integrity: sha512-SYHKEfo83v2n3nEXwSDSAedekGINdfpIxxsMMqr0obtmFiKYVDH9F47sraabddxxAxKQoSsZDIKnfE2hLX3HDg==} engines: {node: '>= 14.15.0'} peerDependencies: @@ -1621,17 +1619,16 @@ packages: dependencies: '@aws-cdk/aws-certificatemanager': 1.193.0_j6i3cfn46lxtg3dfxtfr6gwjsi '@aws-cdk/aws-cloudwatch': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm - '@aws-cdk/aws-ec2': 1.193.0_aelxr2tctgck6ft5trqziwzmui + '@aws-cdk/aws-ec2': 1.193.0_oyrygtfcc75tqlje6mdv4epydy '@aws-cdk/aws-iam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq '@aws-cdk/aws-kms': 1.193.0_wv5he25vlfitynxjm2o4t3p5vu '@aws-cdk/aws-lambda': 1.193.0_hjndse4uvjoh2z652h4gibqbfa '@aws-cdk/aws-s3': 1.193.0_s6ljqdn2iypvkcrzn7mbvz6gaq - '@aws-cdk/aws-ssm': 1.193.0_wv5he25vlfitynxjm2o4t3p5vu + '@aws-cdk/aws-ssm': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm '@aws-cdk/core': 1.193.0_jfsf2uupw3z2wi6nn7gnreoyte '@aws-cdk/cx-api': 1.193.0 constructs: 3.4.251 transitivePeerDependencies: - - '@aws-cdk/assets' - '@aws-cdk/aws-logs' - '@aws-cdk/custom-resources' dev: false @@ -1665,7 +1662,7 @@ packages: '@aws-cdk/aws-cloudwatch': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm '@aws-cdk/aws-codecommit': 1.193.0_fxsm4c6so6jpwbdfd4ammfd45e '@aws-cdk/aws-codestarnotifications': 1.193.0_h5z4mbysj2d57xhjje65guwzkq - '@aws-cdk/aws-ec2': 1.193.0_aelxr2tctgck6ft5trqziwzmui + '@aws-cdk/aws-ec2': 1.193.0_oyrygtfcc75tqlje6mdv4epydy '@aws-cdk/aws-ecr': 1.193.0_t7vgobjyz5zbtb4x3hca7evtr4 '@aws-cdk/aws-ecr-assets': 1.193.0_fxsm4c6so6jpwbdfd4ammfd45e '@aws-cdk/aws-events': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm @@ -1674,7 +1671,7 @@ packages: '@aws-cdk/aws-logs': 1.193.0_fl7hneqefdk7a7rv75sucgtmwm '@aws-cdk/aws-s3': 1.193.0_s6ljqdn2iypvkcrzn7mbvz6gaq '@aws-cdk/aws-s3-assets': 1.193.0_fl7hneqefdk7a7rv75sucgtmwm - '@aws-cdk/aws-secretsmanager': 1.193.0_htsmq7wgkec2uefwunmqkzkjia + '@aws-cdk/aws-secretsmanager': 1.193.0_llxtb453ctumq2vxjrgaghek4y '@aws-cdk/core': 1.193.0_jfsf2uupw3z2wi6nn7gnreoyte '@aws-cdk/region-info': 1.193.0 constructs: 3.4.251 @@ -1767,7 +1764,7 @@ packages: '@aws-cdk/aws-kms': 1.193.0_wv5he25vlfitynxjm2o4t3p5vu '@aws-cdk/aws-lambda': 1.193.0_hjndse4uvjoh2z652h4gibqbfa '@aws-cdk/core': 1.193.0_jfsf2uupw3z2wi6nn7gnreoyte - '@aws-cdk/custom-resources': 1.193.0_ld77ehigssy773vrtmey3cniuq + '@aws-cdk/custom-resources': 1.193.0_7v4p4u6jnphcil74xczvpzwlfy constructs: 3.4.251 punycode: 2.3.0 transitivePeerDependencies: @@ -1795,14 +1792,14 @@ packages: '@aws-cdk/aws-kms': 1.193.0_wv5he25vlfitynxjm2o4t3p5vu '@aws-cdk/aws-lambda': 1.193.0_hjndse4uvjoh2z652h4gibqbfa '@aws-cdk/core': 1.193.0_jfsf2uupw3z2wi6nn7gnreoyte - '@aws-cdk/custom-resources': 1.193.0_ld77ehigssy773vrtmey3cniuq + '@aws-cdk/custom-resources': 1.193.0_7v4p4u6jnphcil74xczvpzwlfy constructs: 3.4.251 transitivePeerDependencies: - '@aws-cdk/aws-logs' - '@aws-cdk/cx-api' dev: false - /@aws-cdk/aws-ec2/1.193.0_aelxr2tctgck6ft5trqziwzmui: + /@aws-cdk/aws-ec2/1.193.0_oyrygtfcc75tqlje6mdv4epydy: resolution: {integrity: sha512-ud9CI3XrsOTQ4OsOxnZdSvPwKSD3Gu5gEVACw/H0ACqDewy64BJOCU7HBHIlf94pVpQCcMyomgKyGIzMgV6nWQ==} engines: {node: '>= 14.15.0'} peerDependencies: @@ -1818,15 +1815,12 @@ packages: '@aws-cdk/aws-kms': 1.193.0_wv5he25vlfitynxjm2o4t3p5vu '@aws-cdk/aws-logs': 1.193.0_fl7hneqefdk7a7rv75sucgtmwm '@aws-cdk/aws-s3': 1.193.0_s6ljqdn2iypvkcrzn7mbvz6gaq - '@aws-cdk/aws-s3-assets': 1.193.0_fl7hneqefdk7a7rv75sucgtmwm - '@aws-cdk/aws-ssm': 1.193.0_wv5he25vlfitynxjm2o4t3p5vu + '@aws-cdk/aws-ssm': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm '@aws-cdk/cloud-assembly-schema': 1.193.0 '@aws-cdk/core': 1.193.0_jfsf2uupw3z2wi6nn7gnreoyte '@aws-cdk/cx-api': 1.193.0 '@aws-cdk/region-info': 1.193.0 constructs: 3.4.251 - transitivePeerDependencies: - - '@aws-cdk/assets' dev: false /@aws-cdk/aws-ecr-assets/1.193.0_fxsm4c6so6jpwbdfd4ammfd45e: @@ -1879,28 +1873,28 @@ packages: constructs: ^3.3.69 dependencies: '@aws-cdk/aws-applicationautoscaling': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm - '@aws-cdk/aws-autoscaling': 1.193.0_upk4xvmulko4zwrdpwfmngkhia + '@aws-cdk/aws-autoscaling': 1.193.0_l2gj7iq54jshudrxdpvnknsadu '@aws-cdk/aws-autoscaling-hooktargets': 1.193.0_sd7ltd5datpnuq3xs2mbxc5gki '@aws-cdk/aws-certificatemanager': 1.193.0_j6i3cfn46lxtg3dfxtfr6gwjsi '@aws-cdk/aws-cloudwatch': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm - '@aws-cdk/aws-ec2': 1.193.0_aelxr2tctgck6ft5trqziwzmui + '@aws-cdk/aws-ec2': 1.193.0_oyrygtfcc75tqlje6mdv4epydy '@aws-cdk/aws-ecr': 1.193.0_t7vgobjyz5zbtb4x3hca7evtr4 '@aws-cdk/aws-ecr-assets': 1.193.0_fxsm4c6so6jpwbdfd4ammfd45e '@aws-cdk/aws-elasticloadbalancing': 1.193.0_6pqcupvooeqlpupvlzhdrord2u - '@aws-cdk/aws-elasticloadbalancingv2': 1.193.0_gqcd7osjtxd6yzxf76nth7r3mu + '@aws-cdk/aws-elasticloadbalancingv2': 1.193.0_dwclitksqmczbyyowpqfwws5du '@aws-cdk/aws-iam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq '@aws-cdk/aws-kms': 1.193.0_wv5he25vlfitynxjm2o4t3p5vu '@aws-cdk/aws-lambda': 1.193.0_hjndse4uvjoh2z652h4gibqbfa '@aws-cdk/aws-logs': 1.193.0_fl7hneqefdk7a7rv75sucgtmwm '@aws-cdk/aws-route53': 1.193.0_wk3iv4ngaohevlam4bfwh7pcnm - '@aws-cdk/aws-route53-targets': 1.193.0_7vgqgy3ctbhuvfr7qo7bzlxkqy + '@aws-cdk/aws-route53-targets': 1.193.0_pyrsnnbhbw2ay3oqrm3lyuclna '@aws-cdk/aws-s3': 1.193.0_s6ljqdn2iypvkcrzn7mbvz6gaq '@aws-cdk/aws-s3-assets': 1.193.0_fl7hneqefdk7a7rv75sucgtmwm - '@aws-cdk/aws-secretsmanager': 1.193.0_htsmq7wgkec2uefwunmqkzkjia - '@aws-cdk/aws-servicediscovery': 1.193.0_agjehwrl4wnqdjmvscrj7zvbaq + '@aws-cdk/aws-secretsmanager': 1.193.0_llxtb453ctumq2vxjrgaghek4y + '@aws-cdk/aws-servicediscovery': 1.193.0_dwclitksqmczbyyowpqfwws5du '@aws-cdk/aws-sns': 1.193.0_s6ljqdn2iypvkcrzn7mbvz6gaq '@aws-cdk/aws-sqs': 1.193.0_wv5he25vlfitynxjm2o4t3p5vu - '@aws-cdk/aws-ssm': 1.193.0_wv5he25vlfitynxjm2o4t3p5vu + '@aws-cdk/aws-ssm': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm '@aws-cdk/core': 1.193.0_jfsf2uupw3z2wi6nn7gnreoyte '@aws-cdk/cx-api': 1.193.0 constructs: 3.4.251 @@ -1913,7 +1907,7 @@ packages: - '@aws-cdk/custom-resources' dev: false - /@aws-cdk/aws-efs/1.193.0_aelxr2tctgck6ft5trqziwzmui: + /@aws-cdk/aws-efs/1.193.0_oyrygtfcc75tqlje6mdv4epydy: resolution: {integrity: sha512-0q2zJvXZJTicC6b/qnxhhNFg0aQGA7jytFM7Xixcix5O6ImCb+OkKbkk0DL8xFP1e+Z5+W2rDvqlGD8rcYbi7A==} engines: {node: '>= 14.15.0'} peerDependencies: @@ -1922,7 +1916,7 @@ packages: '@aws-cdk/cx-api': 1.193.0 constructs: ^3.3.69 dependencies: - '@aws-cdk/aws-ec2': 1.193.0_aelxr2tctgck6ft5trqziwzmui + '@aws-cdk/aws-ec2': 1.193.0_oyrygtfcc75tqlje6mdv4epydy '@aws-cdk/aws-iam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq '@aws-cdk/aws-kms': 1.193.0_wv5he25vlfitynxjm2o4t3p5vu '@aws-cdk/cloud-assembly-schema': 1.193.0 @@ -1930,7 +1924,6 @@ packages: '@aws-cdk/cx-api': 1.193.0 constructs: 3.4.251 transitivePeerDependencies: - - '@aws-cdk/assets' - '@aws-cdk/aws-logs' - '@aws-cdk/aws-s3' dev: false @@ -1943,12 +1936,12 @@ packages: '@aws-cdk/core': 1.193.0 constructs: ^3.3.69 dependencies: - '@aws-cdk/aws-ec2': 1.193.0_aelxr2tctgck6ft5trqziwzmui + '@aws-cdk/aws-ec2': 1.193.0_oyrygtfcc75tqlje6mdv4epydy '@aws-cdk/core': 1.193.0_jfsf2uupw3z2wi6nn7gnreoyte constructs: 3.4.251 dev: false - /@aws-cdk/aws-elasticloadbalancingv2/1.193.0_gqcd7osjtxd6yzxf76nth7r3mu: + /@aws-cdk/aws-elasticloadbalancingv2/1.193.0_dwclitksqmczbyyowpqfwws5du: resolution: {integrity: sha512-ij35Ay5trmFznVEOhKbp/ETfumRa3YRS2ndqb8na/spwn7ISboJ2yEIC5P4FG35gdfwq06yWuyyYBWd3mdoUxA==} engines: {node: '>= 14.15.0'} peerDependencies: @@ -1961,7 +1954,6 @@ packages: dependencies: '@aws-cdk/aws-certificatemanager': 1.193.0_j6i3cfn46lxtg3dfxtfr6gwjsi '@aws-cdk/aws-cloudwatch': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm - '@aws-cdk/aws-ec2': 1.193.0_aelxr2tctgck6ft5trqziwzmui '@aws-cdk/aws-iam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq '@aws-cdk/aws-lambda': 1.193.0_hjndse4uvjoh2z652h4gibqbfa '@aws-cdk/aws-route53': 1.193.0_wk3iv4ngaohevlam4bfwh7pcnm @@ -1972,7 +1964,7 @@ packages: '@aws-cdk/region-info': 1.193.0 constructs: 3.4.251 transitivePeerDependencies: - - '@aws-cdk/assets' + - '@aws-cdk/aws-ec2' - '@aws-cdk/aws-logs' - '@aws-cdk/custom-resources' dev: false @@ -1991,15 +1983,15 @@ packages: constructs: ^3.3.69 dependencies: '@aws-cdk/aws-apigateway': 1.193.0_upk4xvmulko4zwrdpwfmngkhia - '@aws-cdk/aws-autoscaling': 1.193.0_upk4xvmulko4zwrdpwfmngkhia + '@aws-cdk/aws-autoscaling': 1.193.0_l2gj7iq54jshudrxdpvnknsadu '@aws-cdk/aws-codebuild': 1.193.0_ld77ehigssy773vrtmey3cniuq '@aws-cdk/aws-codepipeline': 1.193.0_dfu2olwntafihvull2oke7ivi4 - '@aws-cdk/aws-ec2': 1.193.0_aelxr2tctgck6ft5trqziwzmui + '@aws-cdk/aws-ec2': 1.193.0_oyrygtfcc75tqlje6mdv4epydy '@aws-cdk/aws-ecs': 1.193.0_cu5pzsugp2zvineexa6623gmx4 '@aws-cdk/aws-events': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm '@aws-cdk/aws-iam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq '@aws-cdk/aws-kinesis': 1.193.0_fb53ippgrwc6o3bmc5oulqm4me - '@aws-cdk/aws-kinesisfirehose': 1.193.0_v64ruj6vqiurhxkiymesywpqdq + '@aws-cdk/aws-kinesisfirehose': 1.193.0_llxtb453ctumq2vxjrgaghek4y '@aws-cdk/aws-kms': 1.193.0_wv5he25vlfitynxjm2o4t3p5vu '@aws-cdk/aws-lambda': 1.193.0_hjndse4uvjoh2z652h4gibqbfa '@aws-cdk/aws-logs': 1.193.0_fl7hneqefdk7a7rv75sucgtmwm @@ -2008,7 +2000,7 @@ packages: '@aws-cdk/aws-sqs': 1.193.0_wv5he25vlfitynxjm2o4t3p5vu '@aws-cdk/aws-stepfunctions': 1.193.0_5prrxj3l5spwy6zim4npjrzbwm '@aws-cdk/core': 1.193.0_jfsf2uupw3z2wi6nn7gnreoyte - '@aws-cdk/custom-resources': 1.193.0_ld77ehigssy773vrtmey3cniuq + '@aws-cdk/custom-resources': 1.193.0_7v4p4u6jnphcil74xczvpzwlfy constructs: 3.4.251 transitivePeerDependencies: - '@aws-cdk/assets' @@ -2039,9 +2031,9 @@ packages: '@aws-cdk/custom-resources': 1.193.0 constructs: ^3.3.69 dependencies: - '@aws-cdk/aws-ec2': 1.193.0_aelxr2tctgck6ft5trqziwzmui + '@aws-cdk/aws-ec2': 1.193.0_oyrygtfcc75tqlje6mdv4epydy '@aws-cdk/core': 1.193.0_jfsf2uupw3z2wi6nn7gnreoyte - '@aws-cdk/custom-resources': 1.193.0_ld77ehigssy773vrtmey3cniuq + '@aws-cdk/custom-resources': 1.193.0_7v4p4u6jnphcil74xczvpzwlfy constructs: 3.4.251 dev: false @@ -2077,7 +2069,7 @@ packages: - '@aws-cdk/cx-api' dev: false - /@aws-cdk/aws-kinesisfirehose/1.193.0_v64ruj6vqiurhxkiymesywpqdq: + /@aws-cdk/aws-kinesisfirehose/1.193.0_llxtb453ctumq2vxjrgaghek4y: resolution: {integrity: sha512-nehDBz07r7dwDOjdZwcgLuuyiTDgitOhkLtu3Kd/dgv3K83zEfxWzlit40JY7vfxE6B34uHCjWQAXHAa7NjP9w==} engines: {node: '>= 14.15.0'} peerDependencies: @@ -2089,7 +2081,7 @@ packages: constructs: ^3.3.69 dependencies: '@aws-cdk/aws-cloudwatch': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm - '@aws-cdk/aws-ec2': 1.193.0_aelxr2tctgck6ft5trqziwzmui + '@aws-cdk/aws-ec2': 1.193.0_oyrygtfcc75tqlje6mdv4epydy '@aws-cdk/aws-iam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq '@aws-cdk/aws-kinesis': 1.193.0_fb53ippgrwc6o3bmc5oulqm4me '@aws-cdk/aws-kms': 1.193.0_wv5he25vlfitynxjm2o4t3p5vu @@ -2100,7 +2092,6 @@ packages: '@aws-cdk/region-info': 1.193.0 constructs: 3.4.251 transitivePeerDependencies: - - '@aws-cdk/assets' - '@aws-cdk/cx-api' dev: false @@ -2120,7 +2111,7 @@ packages: constructs: 3.4.251 dev: false - /@aws-cdk/aws-lambda-event-sources/1.193.0_qg64zmashm7t2rdsmtncvmznfa: + /@aws-cdk/aws-lambda-event-sources/1.193.0_u3lhvz6x4k55rd3cwzxax7sbuy: resolution: {integrity: sha512-wwRmr0oxjTIiPnJUlOIts96P5M2WENT/LLpGFJ9KI7Si18eSOfEc4RLAw1HXzuKlUU1VHhubo0Ga7kUMKxZjZQ==} engines: {node: '>= 14.15.0'} peerDependencies: @@ -2135,21 +2126,20 @@ packages: dependencies: '@aws-cdk/aws-apigateway': 1.193.0_upk4xvmulko4zwrdpwfmngkhia '@aws-cdk/aws-dynamodb': 1.193.0_hw4y3fnmtspigwybrnhagitzgi - '@aws-cdk/aws-ec2': 1.193.0_aelxr2tctgck6ft5trqziwzmui + '@aws-cdk/aws-ec2': 1.193.0_oyrygtfcc75tqlje6mdv4epydy '@aws-cdk/aws-events': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm '@aws-cdk/aws-iam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq '@aws-cdk/aws-kinesis': 1.193.0_fb53ippgrwc6o3bmc5oulqm4me '@aws-cdk/aws-lambda': 1.193.0_hjndse4uvjoh2z652h4gibqbfa '@aws-cdk/aws-s3': 1.193.0_s6ljqdn2iypvkcrzn7mbvz6gaq '@aws-cdk/aws-s3-notifications': 1.193.0_4jktmyq4rjkoyfb44azfit3a4u - '@aws-cdk/aws-secretsmanager': 1.193.0_htsmq7wgkec2uefwunmqkzkjia + '@aws-cdk/aws-secretsmanager': 1.193.0_llxtb453ctumq2vxjrgaghek4y '@aws-cdk/aws-sns': 1.193.0_s6ljqdn2iypvkcrzn7mbvz6gaq '@aws-cdk/aws-sns-subscriptions': 1.193.0_7kzgzmrjzvracynar4gtrolizi '@aws-cdk/aws-sqs': 1.193.0_wv5he25vlfitynxjm2o4t3p5vu '@aws-cdk/core': 1.193.0_jfsf2uupw3z2wi6nn7gnreoyte constructs: 3.4.251 transitivePeerDependencies: - - '@aws-cdk/assets' - '@aws-cdk/aws-logs' - '@aws-cdk/cx-api' dev: false @@ -2169,10 +2159,10 @@ packages: '@aws-cdk/aws-applicationautoscaling': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm '@aws-cdk/aws-cloudwatch': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm '@aws-cdk/aws-codeguruprofiler': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm - '@aws-cdk/aws-ec2': 1.193.0_aelxr2tctgck6ft5trqziwzmui + '@aws-cdk/aws-ec2': 1.193.0_oyrygtfcc75tqlje6mdv4epydy '@aws-cdk/aws-ecr': 1.193.0_t7vgobjyz5zbtb4x3hca7evtr4 '@aws-cdk/aws-ecr-assets': 1.193.0_fxsm4c6so6jpwbdfd4ammfd45e - '@aws-cdk/aws-efs': 1.193.0_aelxr2tctgck6ft5trqziwzmui + '@aws-cdk/aws-efs': 1.193.0_oyrygtfcc75tqlje6mdv4epydy '@aws-cdk/aws-events': 1.193.0_hwrqi6tv767pe2ottnl3pwcnqm '@aws-cdk/aws-iam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq '@aws-cdk/aws-kms': 1.193.0_wv5he25vlfitynxjm2o4t3p5vu @@ -2211,7 +2201,7 @@ packages: - '@aws-cdk/aws-s3' dev: false - /@aws-cdk/aws-route53-targets/1.193.0_7vgqgy3ctbhuvfr7qo7bzlxkqy: + /@aws-cdk/aws-route53-targets/1.193.0_pyrsnnbhbw2ay3oqrm3lyuclna: resolution: {integrity: sha512-Cj0zjiwKZ+O8fX5ls8BchQdm7/sVCWnMyb7BfkwviatXum9URGW5tsqdtnicTrzOBKxe2V+ms4Tx6Mj7AgCb3w==} engines: {node: '>= 14.15.0'} peerDependencies: @@ -2224,11 +2214,11 @@ packages: constructs: ^3.3.69 dependencies: '@aws-cdk/aws-apigateway': 1.193.0_upk4xvmulko4zwrdpwfmngkhia - '@aws-cdk/aws-cloudfront': 1.193.0_gqcd7osjtxd6yzxf76nth7r3mu + '@aws-cdk/aws-cloudfront': 1.193.0_5ctpspowm3ljnb7k7tab7mknia '@aws-cdk/aws-cognito': 1.193.0_6tofvxpai7zkmpcugq5ucgdema - '@aws-cdk/aws-ec2': 1.193.0_aelxr2tctgck6ft5trqziwzmui + '@aws-cdk/aws-ec2': 1.193.0_oyrygtfcc75tqlje6mdv4epydy '@aws-cdk/aws-elasticloadbalancing': 1.193.0_6pqcupvooeqlpupvlzhdrord2u - '@aws-cdk/aws-elasticloadbalancingv2': 1.193.0_gqcd7osjtxd6yzxf76nth7r3mu + '@aws-cdk/aws-elasticloadbalancingv2': 1.193.0_dwclitksqmczbyyowpqfwws5du '@aws-cdk/aws-globalaccelerator': 1.193.0_6oli7y3qfgvifjtvl5eb544x3e '@aws-cdk/aws-iam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq '@aws-cdk/aws-route53': 1.193.0_wk3iv4ngaohevlam4bfwh7pcnm @@ -2237,7 +2227,6 @@ packages: '@aws-cdk/region-info': 1.193.0 constructs: 3.4.251 transitivePeerDependencies: - - '@aws-cdk/assets' - '@aws-cdk/aws-lambda' - '@aws-cdk/aws-logs' - '@aws-cdk/custom-resources' @@ -2255,12 +2244,12 @@ packages: '@aws-cdk/custom-resources': 1.193.0 constructs: ^3.3.69 dependencies: - '@aws-cdk/aws-ec2': 1.193.0_aelxr2tctgck6ft5trqziwzmui + '@aws-cdk/aws-ec2': 1.193.0_oyrygtfcc75tqlje6mdv4epydy '@aws-cdk/aws-iam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq '@aws-cdk/aws-logs': 1.193.0_fl7hneqefdk7a7rv75sucgtmwm '@aws-cdk/cloud-assembly-schema': 1.193.0 '@aws-cdk/core': 1.193.0_jfsf2uupw3z2wi6nn7gnreoyte - '@aws-cdk/custom-resources': 1.193.0_ld77ehigssy773vrtmey3cniuq + '@aws-cdk/custom-resources': 1.193.0_7v4p4u6jnphcil74xczvpzwlfy constructs: 3.4.251 dev: false @@ -2296,9 +2285,9 @@ packages: '@aws-cdk/core': 1.193.0 constructs: ^3.3.69 dependencies: - '@aws-cdk/aws-cloudfront': 1.193.0_gqcd7osjtxd6yzxf76nth7r3mu - '@aws-cdk/aws-ec2': 1.193.0_aelxr2tctgck6ft5trqziwzmui - '@aws-cdk/aws-efs': 1.193.0_aelxr2tctgck6ft5trqziwzmui + '@aws-cdk/aws-cloudfront': 1.193.0_5ctpspowm3ljnb7k7tab7mknia + '@aws-cdk/aws-ec2': 1.193.0_oyrygtfcc75tqlje6mdv4epydy + '@aws-cdk/aws-efs': 1.193.0_oyrygtfcc75tqlje6mdv4epydy '@aws-cdk/aws-iam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq '@aws-cdk/aws-lambda': 1.193.0_hjndse4uvjoh2z652h4gibqbfa '@aws-cdk/aws-logs': 1.193.0_fl7hneqefdk7a7rv75sucgtmwm @@ -2367,7 +2356,7 @@ packages: constructs: 3.4.251 dev: false - /@aws-cdk/aws-secretsmanager/1.193.0_htsmq7wgkec2uefwunmqkzkjia: + /@aws-cdk/aws-secretsmanager/1.193.0_llxtb453ctumq2vxjrgaghek4y: resolution: {integrity: sha512-7aPnYsEBhcdS9+xkYCVqHOrvV/uIhvlEJi8qo2kZL8tIlyI/IwCEuB9XpCd4arYIOQ1ZTsD7Yx2hqD/9vdacBA==} engines: {node: '>= 14.15.0'} peerDependencies: @@ -2377,15 +2366,20 @@ packages: '@aws-cdk/cx-api': 1.193.0 constructs: ^3.3.69 dependencies: + '@aws-cdk/aws-ec2': 1.193.0_oyrygtfcc75tqlje6mdv4epydy '@aws-cdk/aws-iam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq + '@aws-cdk/aws-kms': 1.193.0_wv5he25vlfitynxjm2o4t3p5vu '@aws-cdk/aws-lambda': 1.193.0_hjndse4uvjoh2z652h4gibqbfa '@aws-cdk/aws-sam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq '@aws-cdk/core': 1.193.0_jfsf2uupw3z2wi6nn7gnreoyte '@aws-cdk/cx-api': 1.193.0 constructs: 3.4.251 + transitivePeerDependencies: + - '@aws-cdk/aws-logs' + - '@aws-cdk/aws-s3' dev: false - /@aws-cdk/aws-servicediscovery/1.193.0_agjehwrl4wnqdjmvscrj7zvbaq: + /@aws-cdk/aws-servicediscovery/1.193.0_dwclitksqmczbyyowpqfwws5du: resolution: {integrity: sha512-ECDMUpmPLb2w6Ad/oEs46zcWkFCHFZPJRg25bl2I6C6CRYIGWTtMyUzWIGsDs71OAZtR7OPwu/nOlYSs3ZNu0w==} engines: {node: '>= 14.15.0'} peerDependencies: @@ -2393,13 +2387,12 @@ packages: '@aws-cdk/core': 1.193.0 constructs: ^3.3.69 dependencies: - '@aws-cdk/aws-ec2': 1.193.0_aelxr2tctgck6ft5trqziwzmui - '@aws-cdk/aws-elasticloadbalancingv2': 1.193.0_gqcd7osjtxd6yzxf76nth7r3mu + '@aws-cdk/aws-ec2': 1.193.0_oyrygtfcc75tqlje6mdv4epydy + '@aws-cdk/aws-elasticloadbalancingv2': 1.193.0_dwclitksqmczbyyowpqfwws5du '@aws-cdk/aws-route53': 1.193.0_wk3iv4ngaohevlam4bfwh7pcnm '@aws-cdk/core': 1.193.0_jfsf2uupw3z2wi6nn7gnreoyte constructs: 3.4.251 transitivePeerDependencies: - - '@aws-cdk/assets' - '@aws-cdk/aws-iam' - '@aws-cdk/aws-lambda' - '@aws-cdk/aws-logs' @@ -2478,7 +2471,7 @@ packages: - '@aws-cdk/cx-api' dev: false - /@aws-cdk/aws-ssm/1.193.0_wv5he25vlfitynxjm2o4t3p5vu: + /@aws-cdk/aws-ssm/1.193.0_hwrqi6tv767pe2ottnl3pwcnqm: resolution: {integrity: sha512-eVfCgNf3GUkvpr9BDNaNYgUtE6Q6kERu1oXyfW2ps3I3GKu2LZ9KuR8PwR0F4/OzpAsJ2C5TuytiPJd4hshB/g==} engines: {node: '>= 14.15.0'} peerDependencies: @@ -2487,12 +2480,9 @@ packages: constructs: ^3.3.69 dependencies: '@aws-cdk/aws-iam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq - '@aws-cdk/aws-kms': 1.193.0_wv5he25vlfitynxjm2o4t3p5vu '@aws-cdk/cloud-assembly-schema': 1.193.0 '@aws-cdk/core': 1.193.0_jfsf2uupw3z2wi6nn7gnreoyte constructs: 3.4.251 - transitivePeerDependencies: - - '@aws-cdk/cx-api' dev: false /@aws-cdk/aws-stepfunctions/1.193.0_5prrxj3l5spwy6zim4npjrzbwm: @@ -2579,7 +2569,7 @@ packages: - '@balena/dockerignore' - ignore - /@aws-cdk/custom-resources/1.193.0_ld77ehigssy773vrtmey3cniuq: + /@aws-cdk/custom-resources/1.193.0_7v4p4u6jnphcil74xczvpzwlfy: resolution: {integrity: sha512-F1vPsYtY+IBeRkLsrrg+CnSRVE87rL+xYc2UhyZNtJColHA7aQKeiMCzPTDAUoBn0USI/hL7IN5GACwU0etoYg==} engines: {node: '>= 14.15.0'} peerDependencies: @@ -2590,7 +2580,7 @@ packages: constructs: ^3.3.69 dependencies: '@aws-cdk/aws-cloudformation': 1.193.0_4jktmyq4rjkoyfb44azfit3a4u - '@aws-cdk/aws-ec2': 1.193.0_aelxr2tctgck6ft5trqziwzmui + '@aws-cdk/aws-ec2': 1.193.0_oyrygtfcc75tqlje6mdv4epydy '@aws-cdk/aws-iam': 1.193.0_h5z4mbysj2d57xhjje65guwzkq '@aws-cdk/aws-lambda': 1.193.0_hjndse4uvjoh2z652h4gibqbfa '@aws-cdk/aws-logs': 1.193.0_fl7hneqefdk7a7rv75sucgtmwm @@ -2598,7 +2588,6 @@ packages: '@aws-cdk/core': 1.193.0_jfsf2uupw3z2wi6nn7gnreoyte constructs: 3.4.251 transitivePeerDependencies: - - '@aws-cdk/assets' - '@aws-cdk/aws-events' - '@aws-cdk/aws-s3' - '@aws-cdk/cx-api' diff --git a/packages/framework-provider-local/test/helpers/scheduled-helper.ts b/packages/framework-provider-local/test/helpers/scheduled-helper.ts index 585829a43..0d3b67af6 100644 --- a/packages/framework-provider-local/test/helpers/scheduled-helper.ts +++ b/packages/framework-provider-local/test/helpers/scheduled-helper.ts @@ -6,6 +6,6 @@ interface LocalScheduleCommandEnvelope { export function createMockLocalScheduleCommandEnvelope(): Partial { return { - typeName: random.word() + typeName: random.word(), } } diff --git a/packages/framework-provider-local/test/library/scheduled-adapter.test.ts b/packages/framework-provider-local/test/library/scheduled-adapter.test.ts index c4831975f..e927f8af6 100644 --- a/packages/framework-provider-local/test/library/scheduled-adapter.test.ts +++ b/packages/framework-provider-local/test/library/scheduled-adapter.test.ts @@ -1,34 +1,34 @@ /* eslint-disable @typescript-eslint/no-explicit-any */ -import { SinonStub, stub, replace, restore } from 'sinon' +import { SinonStub, stub, replace, restore, fake } from 'sinon' import { rawScheduledInputToEnvelope, LocalScheduleCommandEnvelope } from '../../src/library/scheduled-adapter' import { createMockLocalScheduleCommandEnvelope } from '../helpers/scheduled-helper' -import { UUID } from '@boostercloud/framework-types' +import { BoosterConfig, UUID } from '@boostercloud/framework-types' import { expect } from '../expect' import { random } from 'faker' describe('Local provider scheduled-adapter', () => { describe('rawScheduledInputToEnvelope', () => { - let mockScheduledEnvelop: Partial + let config: BoosterConfig + + let mockScheduledEnvelope: Partial let mockEmptyScheduledEnvelop: Partial let mockUuid: string - let debugStub: SinonStub let generateStub: SinonStub - let logger: any - beforeEach(() => { + config = new BoosterConfig('test') + config.logger = { + debug: fake(), + } as any + mockUuid = random.uuid() - mockScheduledEnvelop = createMockLocalScheduleCommandEnvelope() + mockScheduledEnvelope = createMockLocalScheduleCommandEnvelope() mockEmptyScheduledEnvelop = {} - debugStub = stub() generateStub = stub().returns(mockUuid) - logger = { - debug: debugStub, - } replace(UUID, 'generate', generateStub) }) @@ -37,28 +37,26 @@ describe('Local provider scheduled-adapter', () => { }) it('should call logger.debug', async () => { - await rawScheduledInputToEnvelope(mockScheduledEnvelop, logger) + await rawScheduledInputToEnvelope(config, mockScheduledEnvelope) - expect(debugStub).to.have.been.calledOnceWith( + expect(config.logger?.debug).to.have.been.calledOnceWith( + '[Booster]|rawScheduledInputToEnvelope: ', 'Received LocalScheduleCommand request: ', - mockScheduledEnvelop + mockScheduledEnvelope ) }) it('should thrown an exception for empty typeName', async () => { - const error = new Error( - `typeName is not defined or empty, scheduled command envelope should have the structure {typeName: string }, but you gave ${JSON.stringify( - mockEmptyScheduledEnvelop - )}` + await expect(rawScheduledInputToEnvelope(config, mockEmptyScheduledEnvelop)).to.be.rejectedWith( + 'typeName is not defined or empty, scheduled command envelope should have the structure {typeName: string }, but you gave {}' ) - expect(rawScheduledInputToEnvelope(mockEmptyScheduledEnvelop, logger)).to.be.rejectedWith(error) }) it('should generate expected envelop', async () => { - const result = await rawScheduledInputToEnvelope(mockScheduledEnvelop, logger) + const result = await rawScheduledInputToEnvelope(config, mockScheduledEnvelope) expect(result).to.be.deep.equal({ requestID: mockUuid, - typeName: mockScheduledEnvelop.typeName + typeName: mockScheduledEnvelope.typeName, }) }) }) diff --git a/packages/framework-types/src/schedule.ts b/packages/framework-types/src/schedule.ts index db726843c..2a8ea47d7 100644 --- a/packages/framework-types/src/schedule.ts +++ b/packages/framework-types/src/schedule.ts @@ -1,4 +1,5 @@ export interface ScheduleInterface { + readonly second?: string readonly minute?: string readonly hour?: string readonly day?: string