Feat: add auth provider to users on sign in (#3739)
* feat: merge a new authentication method onto existing user records when emails match * adds test for invite acceptance and auth provider creation * addresses comments - test existing user and invites in different test cases - update lastActiveAt syncronously when an invite is accepted * sort arrays in test to prevent nondeterministic test behaivior when doing array compare
This commit is contained in:
@@ -39,7 +39,7 @@ describe("#team.update", () => {
|
||||
});
|
||||
const body = await res.json();
|
||||
expect(res.status).toEqual(200);
|
||||
expect(body.data.allowedDomains).toEqual([
|
||||
expect(body.data.allowedDomains.sort()).toEqual([
|
||||
"example-company.com",
|
||||
"example-company.org",
|
||||
]);
|
||||
@@ -47,7 +47,7 @@ describe("#team.update", () => {
|
||||
const teamDomains: TeamDomain[] = await TeamDomain.findAll({
|
||||
where: { teamId: team.id },
|
||||
});
|
||||
expect(teamDomains.map((d) => d.name)).toEqual([
|
||||
expect(teamDomains.map((d) => d.name).sort()).toEqual([
|
||||
"example-company.com",
|
||||
"example-company.org",
|
||||
]);
|
||||
|
||||
Reference in New Issue
Block a user