@tellescope/sdk 1.4.1 → 1.4.3

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.
@@ -1 +1 @@
1
- {"version":3,"file":"tests.d.ts","sourceRoot":"","sources":["../../../src/tests/tests.ts"],"names":[],"mappings":"AA42DA,eAAO,MAAM,qBAAqB,qBA8IjC,CAAA;AA4ID,eAAO,MAAM,cAAc,qBAqC1B,CAAA;AA0eD,eAAO,MAAM,6BAA6B,qBAgCzC,CAAA;AAED,eAAO,MAAM,0BAA0B,qBAmFtC,CAAA;AAoED,eAAO,MAAM,eAAe,qBA8C3B,CAAA;AAED,eAAO,MAAM,oBAAoB,6BAsBhC,CAAA;AAED,eAAO,MAAM,oCAAoC,qBAgIhD,CAAA"}
1
+ {"version":3,"file":"tests.d.ts","sourceRoot":"","sources":["../../../src/tests/tests.ts"],"names":[],"mappings":"AA42DA,eAAO,MAAM,qBAAqB,qBA8IjC,CAAA;AA4ID,eAAO,MAAM,cAAc,qBAqC1B,CAAA;AA0eD,eAAO,MAAM,6BAA6B,qBAgCzC,CAAA;AAED,eAAO,MAAM,0BAA0B,qBAmFtC,CAAA;AAoED,eAAO,MAAM,eAAe,qBA8C3B,CAAA;AAED,eAAO,MAAM,oBAAoB,6BAsBhC,CAAA;AAED,eAAO,MAAM,oCAAoC,qBA8IhD,CAAA"}
@@ -1688,7 +1688,7 @@ var files_tests = function () { return __awaiter(void 0, void 0, void 0, functio
1688
1688
  ])];
1689
1689
  case 16:
1690
1690
  _c.sent();
1691
- return [4 /*yield*/, (0, testing_1.wait)(undefined, 1000)]; // wait for files to be deleted as side effect
1691
+ return [4 /*yield*/, (0, testing_1.wait)(undefined, 1250)]; // wait for files to be deleted as side effect
1692
1692
  case 17:
1693
1693
  _c.sent(); // wait for files to be deleted as side effect
1694
1694
  return [4 /*yield*/, (0, testing_1.async_test)("Files cleaned up as side effect of deleting enduser", function () { return sdkNonAdmin.api.files.getSome({ filter: { enduserId: enduser.id } }); }, { onResult: function (fs) { return fs.length === 0; } })];
@@ -3680,7 +3680,19 @@ var self_serve_appointment_booking_tests = function () { return __awaiter(void 0
3680
3680
  calendarEventTemplateId: event30min.id,
3681
3681
  from: new Date(),
3682
3682
  restrictedByState: false,
3683
- }); }, { onResult: function (r) { return r.availabilityBlocks.length === 4; } })];
3683
+ }); }, { onResult: function (r) {
3684
+ if (r.availabilityBlocks.length !== 4)
3685
+ return false; // 2 providers with 1 hour availability for 30 minute meetings
3686
+ var user1block1_ET = r.availabilityBlocks.find(function (b) { return b.userId === sdk.userInfo.id; });
3687
+ var user2block1_PT = r.availabilityBlocks.find(function (b) { return b.userId === sdkNonAdmin.userInfo.id; });
3688
+ if (!(user1block1_ET && user2block1_PT))
3689
+ return false; // should be slots for both users
3690
+ if (user2block1_PT.startTimeInMS - user1block1_ET.startTimeInMS !== 1000 * 60 * 60 * 3) {
3691
+ console.log(user1block1_ET.startTimeInMS, user2block1_PT.startTimeInMS, user1block1_ET.startTimeInMS - user2block1_PT.startTimeInMS);
3692
+ return false; // difference should be three hours, since same availability in different timezones
3693
+ }
3694
+ return true;
3695
+ } })];
3684
3696
  case 11:
3685
3697
  _a.sent();
3686
3698
  return [4 /*yield*/, enduserSDK.api.calendar_events.get_appointment_availability({