-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
9155321
commit 2cd78b6
Showing
18 changed files
with
456 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
const { introspectAs } = require("./utils"); | ||
|
||
describe("flow_document_templates", () => { | ||
describe("public", () => { | ||
let i; | ||
beforeAll(async () => { | ||
i = await introspectAs("public"); | ||
}); | ||
|
||
// TODO: Check this - seems unnecessary / incorrect? | ||
test.skip("cannot query flow_document_templates", () => { | ||
expect(i.queries).not.toContain("flow_document_templates"); | ||
}); | ||
|
||
test("cannot create, update, or delete flow_document_templates", () => { | ||
expect(i).toHaveNoMutationsFor("flow_document_templates"); | ||
}); | ||
}); | ||
|
||
describe("admin", () => { | ||
let i; | ||
beforeAll(async () => { | ||
i = await introspectAs("admin"); | ||
}); | ||
|
||
test("can query flow_document_templates", () => { | ||
expect(i.queries).toContain("flow_document_templates"); | ||
}); | ||
|
||
test("can create, update, or delete flow_document_templates", () => { | ||
expect(i.mutations).toContain("insert_flow_document_templates"); | ||
expect(i.mutations).toContain("insert_flow_document_templates_one"); | ||
expect(i.mutations).toContain("update_flow_document_templates_by_pk"); | ||
expect(i.mutations).toContain("delete_flow_document_templates_by_pk"); | ||
}); | ||
}); | ||
|
||
describe("platformAdmin", () => { | ||
let i; | ||
beforeAll(async () => { | ||
i = await introspectAs("platformAdmin"); | ||
}); | ||
|
||
test("cannot query flow_document_templates", () => { | ||
expect(i.queries).not.toContain("flow_document_templates"); | ||
}); | ||
|
||
test("cannot create, update, or delete flow_document_templates", () => { | ||
expect(i).toHaveNoMutationsFor("flow_document_templates"); | ||
}); | ||
}); | ||
|
||
describe("teamEditor", () => { | ||
let i; | ||
beforeAll(async () => { | ||
i = await introspectAs("teamEditor"); | ||
}); | ||
|
||
test("cannot query flow_document_templates", () => { | ||
expect(i.queries).not.toContain("flow_document_templates"); | ||
}); | ||
|
||
test("cannot create, update, or delete flow_document_templates", () => { | ||
expect(i).toHaveNoMutationsFor("flow_document_templates"); | ||
}); | ||
}); | ||
|
||
describe("api", () => { | ||
beforeAll(async () => { | ||
i = await introspectAs("api"); | ||
}); | ||
|
||
test("can query flow_document_templates", () => { | ||
expect(i.queries).toContain("flow_document_templates"); | ||
}); | ||
|
||
test("cannot create, update, or delete flow_document_templates", () => { | ||
expect(i).toHaveNoMutationsFor("flow_document_templates"); | ||
}); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.