Skip to content

Commit

Permalink
fix: remove lines not needed and add one test
Browse files Browse the repository at this point in the history
  • Loading branch information
vanbasten17 committed Jun 25, 2024
1 parent 93296f6 commit 821f01b
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
1 change: 0 additions & 1 deletion packages/botonic-core/src/models/legacy-types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -248,7 +248,6 @@ export interface BotRequest {
input: Input
lastRoutePath: RoutePath
session: Session
followUpAction?: any
}

/** The response of the bot for the triggered actions, which can be
Expand Down
9 changes: 9 additions & 0 deletions packages/botonic-core/tests/handoff.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -127,4 +127,13 @@ describe('Handoff', () => {
})
expect(builder._session._botonic_action).toEqual(expectedBotonicAction)
})

test('defines create_test_integration_case_with_payload for test integrations', () => {
const builder = new HandOffBuilder({
is_test_integration: true,
}).withOnFinishPayload('payload1')
builder.handOff()
const expectedBotonicAction = 'create_test_integration_case:payload1'
expect(builder._session._botonic_action).toEqual(expectedBotonicAction)
})
})
1 change: 0 additions & 1 deletion packages/botonic-plugin-flow-builder/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,6 @@ export default class BotonicPluginFlowBuilder implements Plugin {
}

async pre(request: PluginPreRequest): Promise<void> {
request.session.is_test_integration = true
this.currentRequest = request
this.cmsApi = await FlowBuilderApi.create({
url: this.resolveFlowUrl(request),
Expand Down

0 comments on commit 821f01b

Please sign in to comment.