
Security News
ESLint Adds Official Support for Linting HTML
ESLint now supports HTML linting with 48 new rules, expanding its language plugin system to cover more of the modern web development stack.
Small and fast Typescript unit testing library with no dependencies
Small and fast Typescript unit testing library with no dependencies.
yarn add briefest --dev
npm install briefest --save-dev
UMD file is also available on unpkg:
<script src="https://unpkg.com/briefest/briefest.umd.min.js"></script>
You can use the library via window.briefest
.
import { test } from "briefest"
test("Simple tests", (t, done) => {
t.isPrimitive(-1)
t.isPrimitive(2n ** 8n)
t.isEqualPrimitive(undefined, undefined)
t.isEqual("", "")
t.isEqual(64n, 2n ** 6n)
t.isNotEqual({}, {})
t.isNotEqual(new Date(), new Date())
done()
})
import { test } from "briefest"
const callbackTest = (cb: (v: number) => void) => setTimeout(() => cb(500), 200)
const asyncTest = () => new Promise<number>((resolve) => setTimeout(() => resolve(600), 100))
test("Async tests", (t, done) => {
callbackTest(async (val) => {
t.isEqual(500, val)
// an async/await example
t.isEqual(600, await asyncTest())
done()
})
})
Feel free to send some pull request or issue.
MIT license
© 2020 Jose Quintana
FAQs
Small and fast Typescript unit testing library with no dependencies
We found that briefest demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
ESLint now supports HTML linting with 48 new rules, expanding its language plugin system to cover more of the modern web development stack.
Security News
CISA is discontinuing official RSS support for KEV and cybersecurity alerts, shifting updates to email and social media, disrupting automation workflows.
Security News
The MCP community is launching an official registry to standardize AI tool discovery and let agents dynamically find and install MCP servers.