Skip to content

Commit 4475043

Browse files
authored
Merge pull request #16 from TourConnect/feature/check_bookingrefid
Send bookingPartnerId to check the bookingRefID against
2 parents cafe4df + edd270b commit 4475043

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

index.js

+1
Original file line numberDiff line numberDiff line change
@@ -618,6 +618,7 @@ class Plugin {
618618
email: R.path(['emailAddress'], holder),
619619
phone: R.pathOr('', ['phone'], holder),
620620
bookingRefID: reference,
621+
bookingPartnerId: bookingPartnerId,
621622
...R.omit(['iat', 'currency'], dataForBooking),
622623
// notes,
623624
},

index.test.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ describe('search tests', () => {
4040
const token = {
4141
endpoint: process.env.ti2_bonza_endpoint,
4242
apiKey: process.env.ti2_bonza_apiKey,
43-
bookingPartnerId: 181
43+
bookingPartnerId: 181,
4444
};
4545
const dateFormat = 'DD/MM/YYYY';
4646
const dateFormatCB = 'YYYY-MM-DD';
@@ -179,7 +179,7 @@ describe('search tests', () => {
179179
expect(availabilityKey).toBeTruthy();
180180
});
181181
let booking;
182-
const reference = faker.datatype.uuid();
182+
const bookingRefId = faker.datatype.uuid();
183183
it('should be able to create a booking', async () => {
184184
const fullName = faker.name.findName().split(' ');
185185
const retVal = await app.createBooking({
@@ -214,7 +214,7 @@ describe('search tests', () => {
214214
phone: "888888877",
215215
country: faker.address.countryCode(),
216216
},
217-
reference,
217+
reference: bookingRefId,
218218
},
219219
});
220220
expect(retVal.booking).toBeTruthy();

0 commit comments

Comments
 (0)