-
Notifications
You must be signed in to change notification settings - Fork 326
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add a test with a timeout for unitTest
- Loading branch information
Showing
2 changed files
with
27 additions
and
2 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import { assert } from "testing/asserts"; | ||
import { execProcess } from "../../../src/core/process.ts"; | ||
import { quartoDevCmd } from "../../utils.ts"; | ||
import { unitTest } from "../../test.ts"; | ||
|
||
const testPassthroughCmd = (name: string, command: string, args: string[]) => { | ||
unitTest(name, async () => { | ||
const result = await execProcess({ | ||
cmd: [ | ||
quartoDevCmd(), | ||
command, | ||
...args, | ||
] | ||
}); | ||
assert(result.success); | ||
}); | ||
} | ||
|
||
// Check Pandoc passthrough | ||
testPassthroughCmd("passthrough-pandoc", "pandoc", ["--version"]); | ||
// Check Typst passthrough | ||
testPassthroughCmd("passthrough-typst", "typst", ["--version"]); |
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