Fix tests

This commit is contained in:
Umberto Pepato
2020-05-04 15:12:52 +02:00
parent 0fc8174cc9
commit d873e3a77e
2 changed files with 3 additions and 4 deletions

View File

@@ -29,7 +29,7 @@ async function runScript(name: string): Promise<string> {
Deno.test("basic script with env variable", async () => {
const output = await runScript("basic");
assertEquals(output, expectedOutput);
assert(new RegExp(`${expectedOutput}\n*`).test(output));
});
Deno.test("deno run", async () => {
@@ -49,12 +49,12 @@ Deno.test("shell script", async () => {
Deno.test("serial scripts", async () => {
const output = await runScript("multiple");
assertEquals(output, "one\ntwo\n");
assert(/one\n+two\n*/.test(output));
});
Deno.test("parallel scripts", async () => {
const output = await runScript("multiplepll");
assertEquals(output, "two\none\n");
assert(/two\n+one\n*/.test(output));
});
Deno.test("deno permissions", async () => {