Skip to content

TomokiMiyauci/unitest

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Unitest

Deno-first universal unit testing framework

deno land nest.land

release deno version deno doc

test codecov DeepSource DeepScan grade

Semver Conventional Commits semantic-release: angular license


🚧 This is beta

Features

  • πŸ¦• Deno-first
    It has been designed with Deno first, and actively uses the Deno Runtime API.

  • 🌎 Universal
    It is also compatible to work in browsers and Node.js environments. Use the compatible compat module instead of the Deno Runtime API.

  • πŸƒ Like jest but not jest
    You can express declarative tests around the symbolic expect in jest. Also, all matchers are composable and customizable. jest and jest-extended matchers are provided as presets.

  • ♻️ Compositable
    Unitest is also intended to be used in a browser.
    For this reason, we provide a composable interface to keep the bundle size as small as possible.

  • πŸ“„ TypeScript-first
    Type-safe tests can be expressed. A type filter restricts the availability of only those matchers that satisfy the data type under test.
    It also keeps the bundle size small by transferring part of the data type validation to TypeScript.

  • 🐺 Isolated
    Each module is independent, with no dependency on context. This means that they can be combined with any module.

Requirements

  • deno 1.15+

Getting Started

Visit https://unitest.vercel.app/ to get started with Unitest.

Quick view

All available matchers

import { expect, test } from "https://deno.land/x/unitest@$VERSION/mod.ts";

test({
  name: "should not equal",
  fn: () => {
    expect("Deno").not.toBe("Node");
  },
});

then, deno test

Currently the test runner CLI relies on the Deno CLI. This is subject to change in the future.

Contributing

Please see our CONTRIBUTING.md.

License

Copyright Β© 2021-present TomokiMiyauci.

Released under the MIT license

About

πŸƒ Deno-first universal unit testing framework

Topics

Resources

License

Code of conduct

Security policy

Stars

Watchers

Forks

Sponsor this project

Languages