import { expect, it } from "@effect/vitest";
import { Effect } from "effect";
import { Fetch, FetchTest } from "./fetch.js";
import { FRConfigTest } from "./Config.js";
it.effect("should fetch a route", () =>
Effect.gen(function* () {
const { get } = yield* Fetch;
const todos = yield* get("/todos");
expect(todos).toStrictEqual({});
}).pipe(Effect.provide(FetchTest), Effect.provide(FRConfigTest)),
);
import { expect, it } from "@effect/vitest";
import { Effect } from "effect";
import { Fetch, FetchTest } from "./fetch.js";
import { FRConfigTest } from "./Config.js";
it.effect("should fetch a route", () =>
Effect.gen(function* () {
const { get } = yield* Fetch;
const todos = yield* get("/todos");
expect(todos).toStrictEqual({});
}).pipe(Effect.provide(FetchTest), Effect.provide(FRConfigTest)),
);