Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

@deno/shim-deno-test

denoland323.2kMIT0.5.0TypeScript support: included

Deno.test only shim.

shim, deno, test, node.js

readme

@deno/shim-deno-test

Subset of @deno/shim-deno for only Deno.test.

import { Deno, test, testDefinitions } from "@deno/shim-deno-test";

Deno.test("some test", () => {
  // test here
});

// or
test("some other test", () => {
  // test here
});

// read from testDefinitions here
testDefinitions.length === 2;

Note - Not a Test Runner

This shim is not a test runner. It simply collects tests into the testDefinitions array. The idea is that you run a module that does Deno.test calls and then you splice out the test definitions from testDefinitions (ex. const definitions = testDefinitions.splice(0, testDefinitions.length)) and provide those to a test runner.