Skip to content

Commit cef854f

Browse files
additional test case
1 parent be02ebd commit cef854f

1 file changed

Lines changed: 22 additions & 0 deletions

File tree

src/deploy/functions/release/fabricator.spec.ts

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1805,6 +1805,28 @@ describe("Fabricator", () => {
18051805
}),
18061806
);
18071807
});
1808+
1809+
it("always sets callable triggers to public on creation", async () => {
1810+
runv2.createService.resolves({ uri: "https://service", name: "service" } as any);
1811+
run.setInvokerCreate.resolves();
1812+
1813+
const ep = endpoint(
1814+
{ callableTrigger: {} },
1815+
{
1816+
platform: "run",
1817+
baseImageUri: "gcr.io/base",
1818+
command: ["cmd"],
1819+
args: ["arg"],
1820+
},
1821+
);
1822+
await fab.createRunFunction(ep);
1823+
1824+
expect(run.setInvokerCreate).to.have.been.calledWith(
1825+
ep.project,
1826+
sinon.match.string,
1827+
["public"],
1828+
);
1829+
});
18081830
});
18091831

18101832
describe("updateRunFunction", () => {

0 commit comments

Comments
 (0)