Skip to content

Commit c80f8db

Browse files
committed
Correction to mocks due to changes in commit 9839a7f
1 parent ca5914d commit c80f8db

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/Dao/MySql/__mocks__/MockMySqlDatasourceUser.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ const mockLoadResult = [
5050
];
5151
const mockLoadFn = async function (fields: Array<string> = null, filter: string = null, maxRows: number = 100) {
5252
const flds= fields;
53-
const email = filter.substring("WHERE 'Email' = ".length);
53+
const email = filter.substring("'Email' == \"".length, filter.length - 1);
5454

5555
return mockLoadResult.filter(r => r.getField('Email').value == email);
5656
}

src/Dao/MySql/__mocks__/MockMySqlDatasourceUserSession.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ const mockLoadResult = [
4646
];
4747
const mockLoadFn = async function (fields: Array<string> = null, filter: string = null, maxRows: number = 100) {
4848
const flds= fields;
49-
const userId = filter.substring("WHERE 'UserId' = ".length, filter.length - " AND 'EndDate IS NULL".length);
49+
const userId = filter.substring("'UserId' == ".length, filter.length - " AND 'EndDate IS NULL".length);
5050

5151
return mockLoadResult.filter(r => r.getField('UserId').value == userId);
5252
}

0 commit comments

Comments
 (0)