Skip to content

Commit

Permalink
tsc
Browse files Browse the repository at this point in the history
  • Loading branch information
tommoor committed Sep 21, 2022
1 parent cfabc2e commit d825ed9
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions server/models/TeamDomain.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,12 +45,13 @@ describe("team domain model", () => {

it("should not allow creation of domains within restricted list", async () => {
env.DEPLOYMENT = "hosted";
const TeamDomain = import("./TeamDomain");
const TeamDomain = await import("./TeamDomain");
const team = await buildTeam();
const user = await buildAdmin({ teamId: team.id });

let error;
try {
// @ts-expect-error TeamDomain type
await TeamDomain.create({
teamId: team.id,
name: "gmail.com",
Expand All @@ -64,12 +65,13 @@ describe("team domain model", () => {

it("should ignore casing and spaces when creating domains", async () => {
env.DEPLOYMENT = "hosted";
const TeamDomain = import("./TeamDomain");
const TeamDomain = await import("./TeamDomain");
const team = await buildTeam();
const user = await buildAdmin({ teamId: team.id });

let error;
try {
// @ts-expect-error TeamDomain type
await TeamDomain.create({
teamId: team.id,
name: " GMail.com ",
Expand Down

0 comments on commit d825ed9

Please sign in to comment.