Files
create-github-app-token/tests/index.js
T
Parker Brown 10f155294b test: integration tests (#40)
Co-authored-by: Gregor Martynus <39992+gr2m@users.noreply.github.com>
2023-09-05 08:32:55 -07:00

15 lines
380 B
JavaScript

import { readdirSync } from "node:fs";
import { execa } from "execa";
import test from "ava";
const tests = readdirSync("tests").filter((file) => file.endsWith(".test.js"));
for (const file of tests) {
test(file, async (t) => {
const { stderr, stdout } = await execa("node", [`tests/${file}`]);
t.snapshot(stderr, "stderr");
t.snapshot(stdout, "stdout");
});
}