Skip to content

Commit

Permalink
cleanup test timings
Browse files Browse the repository at this point in the history
  • Loading branch information
Šimon Macek committed Oct 22, 2024
1 parent 3ee756a commit 97147f1
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion test/cypress/fixtures/thisCampaign.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
},
{
"phase_type": "entry_enabled",
"date_from": "2024-09-15",
"date_from": "2024-09-16",
"date_to": "2024-10-02"
},
{
Expand Down
7 changes: 4 additions & 3 deletions test/cypress/support/commonTests.ts
Original file line number Diff line number Diff line change
Expand Up @@ -397,9 +397,10 @@ const fixtureTokenExpiration = new Date('2024-09-24T20:36:03Z');
const timeUntilRefresh = 60 * 1000; // miliseconds (because used in cy.tick)
export const fixtureTokenExpirationTime = fixtureTokenExpiration.getTime();
export const timeUntilExpiration = timeUntilRefresh * 2;
// 2 min before JWT expires (challenge inactive)
// 2 min before JWT expires
export const systemTimeLoggedIn =
fixtureTokenExpirationTime - timeUntilExpiration;
// challenge active start date
// time before challenge starts
export const systemTimeChallengeInactive = new Date('2024-09-15T23:59:00.000Z');
// time after challenge starts
export const systemTimeChallengeActive = new Date('2024-09-16T00:01:00.000Z');
export const systemTimeChallengeInactive = new Date('2024-06-15T00:00:00.000Z');

0 comments on commit 97147f1

Please sign in to comment.