Skip to content

Commit

Permalink
fix: Remove flaky time test
Browse files Browse the repository at this point in the history
  • Loading branch information
dougmartin committed May 29, 2024
1 parent 345485a commit dc04dff
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions query-creator/create-query/tests/unit/generated-sql.js
Original file line number Diff line number Diff line change
Expand Up @@ -819,15 +819,15 @@ FROM
`

exports.expectedUserLogSQLresult = `
-- name log.username IN ('[email protected]', '[email protected]') AND log.activity IN ('activity-1', 'activity-2') AND time >= 1704171600 AND time <= 1709528400
-- name log.username IN ('[email protected]', '[email protected]') AND log.activity IN ('activity-1', 'activity-2')
-- type user event log
-- reportType user-event-log
-- usernames: ["[email protected]","[email protected]"]
-- activities: ["activity-1","activity-2"]
SELECT *
FROM "undefined"."logs_by_time" log
WHERE log.username IN ('[email protected]', '[email protected]') AND log.activity IN ('activity-1', 'activity-2') AND time >= 1704171600 AND time <= 1709528400
WHERE log.username IN ('[email protected]', '[email protected]') AND log.activity IN ('activity-1', 'activity-2')
`

exports.expectedNarrowLearnerLogWithNamesSqlResult = `
Expand Down
2 changes: 1 addition & 1 deletion query-creator/create-query/tests/unit/test-handler.js
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ describe('Query creation unreportable runnable', function () {
describe('Query creation for log data', function () {

it('verifies successful query creation of user log data', async () => {
const generatedSQLresult = await aws.generateUserLogSQL(["[email protected]", "[email protected]"], ["activity-1", "activity-2"], "1/2/2024", "3/4/2024");
const generatedSQLresult = await aws.generateUserLogSQL(["[email protected]", "[email protected]"], ["activity-1", "activity-2"]);
const normalizedGeneratedSQLresult = normalizeSQL(generatedSQLresult);
const normalizedExpectedSQLresult = normalizeSQL(expectedUserLogSQLresult);
expect(normalizedGeneratedSQLresult).to.be.equal(normalizedExpectedSQLresult);
Expand Down

0 comments on commit dc04dff

Please sign in to comment.