@dillonkearns/elm-graphql
Version:
<img src="https://cdn.jsdelivr.net/gh/martimatix/logo-graphqelm/logo.svg" alt="dillonearns/elm-graphql logo" width="40%" align="right">
52 lines (38 loc) • 1.42 kB
JavaScript
/*
MIT License http://www.opensource.org/licenses/mit-license.php
Author Tobias Koppers @sokra
*/
;
const HookTester = require("./HookTester");
const AsyncSeriesHook = require("../AsyncSeriesHook");
const AsyncSeriesBailHook = require("../AsyncSeriesBailHook");
const AsyncSeriesWaterfallHook = require("../AsyncSeriesWaterfallHook");
const AsyncSeriesLoopHook = require("../AsyncSeriesLoopHook");
describe("AsyncSeriesHook", () => {
it("should have to correct behavior", async () => {
const tester = new HookTester(args => new AsyncSeriesHook(args));
const result = await tester.run();
expect(result).toMatchSnapshot();
});
});
describe("AsyncSeriesBailHook", () => {
it("should have to correct behavior", async () => {
const tester = new HookTester(args => new AsyncSeriesBailHook(args));
const result = await tester.run();
expect(result).toMatchSnapshot();
});
});
describe("AsyncSeriesWaterfallHook", () => {
it("should have to correct behavior", async () => {
const tester = new HookTester(args => new AsyncSeriesWaterfallHook(args));
const result = await tester.run();
expect(result).toMatchSnapshot();
});
});
describe("AsyncSeriesLoopHook", () => {
it("should have to correct behavior", async () => {
const tester = new HookTester(args => new AsyncSeriesLoopHook(args));
const result = await tester.runForLoop();
expect(result).toMatchSnapshot();
});
});