@trayio/cdk-dsl 5.22.0-unstable → 5.22.1-unstable

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -205,7 +205,7 @@ exports.OperationHandlerSetup = {
205
205
  const descriptor = readOperationDescriptorFile();
206
206
  assertPollingTriggerType(descriptor, 'configureTriggerPollCreateHandler');
207
207
  const { name } = descriptor;
208
- const handler = OperationHandlerConfiguration.withNameAndHandlerType(`${name}_poll`, OperationHandler_1.OperationHandlerType.TriggerPollCreate)
208
+ const handler = OperationHandlerConfiguration.withNameAndHandlerType(`${name}`, OperationHandler_1.OperationHandlerType.TriggerPollCreate)
209
209
  .addInputValidation((v) => v
210
210
  .condition((_ctx, input) => input.pollingInterval === undefined ||
211
211
  (typeof input.pollingInterval.value === 'number' &&
@@ -258,7 +258,7 @@ exports.OperationHandlerSetup = {
258
258
  const descriptor = readOperationDescriptorFile();
259
259
  assertPollingTriggerType(descriptor, 'configureTriggerPollDestroyHandler');
260
260
  const { name } = descriptor;
261
- const handler = OperationHandlerConfiguration.withNameAndHandlerType(`${name}_poll_destroy`, OperationHandler_1.OperationHandlerType.TriggerPollDestroy).usingComposite(pollingLifecycleNoOpBody);
261
+ const handler = OperationHandlerConfiguration.withNameAndHandlerType(`${name}_destroy`, OperationHandler_1.OperationHandlerType.TriggerPollDestroy).usingComposite(pollingLifecycleNoOpBody);
262
262
  OperationHandlerRegistry.register(handler);
263
263
  return {
264
264
  name: handler.name,
@@ -61,10 +61,10 @@ describe('OperationHandlerSetup polling', () => {
61
61
  jest.clearAllMocks();
62
62
  });
63
63
  describe('configureTriggerPollCreateHandler', () => {
64
- it('registers TriggerPollCreate with _poll suffix when triggerType is polling', () => {
64
+ it('registers TriggerPollCreate with the base operation name when triggerType is polling', () => {
65
65
  pointCallSiteAt(pollingFixtureFolder);
66
66
  const ref = OperationHandlerSetup_1.OperationHandlerSetup.configureTriggerPollCreateHandler();
67
- expect(ref.name).toBe('new_records_poll');
67
+ expect(ref.name).toBe('new_records');
68
68
  const handler = resolveHandler(ref);
69
69
  expect(handler.handlerType).toBe(OperationHandler_1.OperationHandlerType.TriggerPollCreate);
70
70
  expect(handler.implementation._tag).toBe('CompositeOperationHandler');
@@ -157,10 +157,10 @@ describe('OperationHandlerSetup polling', () => {
157
157
  });
158
158
  });
159
159
  describe('configureTriggerPollDestroyHandler', () => {
160
- it('registers TriggerPollDestroy with _poll_destroy suffix', () => {
160
+ it('registers TriggerPollDestroy with _destroy suffix', () => {
161
161
  pointCallSiteAt(pollingFixtureFolder);
162
162
  const ref = OperationHandlerSetup_1.OperationHandlerSetup.configureTriggerPollDestroyHandler();
163
- expect(ref.name).toBe('new_records_poll_destroy');
163
+ expect(ref.name).toBe('new_records_destroy');
164
164
  const handler = resolveHandler(ref);
165
165
  expect(handler.handlerType).toBe(OperationHandler_1.OperationHandlerType.TriggerPollDestroy);
166
166
  expect(handler.implementation._tag).toBe('CompositeOperationHandler');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@trayio/cdk-dsl",
3
- "version": "5.22.0-unstable",
3
+ "version": "5.22.1-unstable",
4
4
  "description": "A DSL for connector development",
5
5
  "exports": {
6
6
  "./*": "./dist/*.js"
@@ -14,7 +14,7 @@
14
14
  "access": "public"
15
15
  },
16
16
  "dependencies": {
17
- "@trayio/commons": "5.22.0-unstable"
17
+ "@trayio/commons": "5.22.1-unstable"
18
18
  },
19
19
  "typesVersions": {
20
20
  "*": {