{"library":"node-test","title":"node-test","description":"node-test is a simple, asynchronous test runner for Node.js, currently at version 1.4.6. Its core design principles emphasize concurrent test execution, the absence of global testing primitives like `describe` or `it`, and the ability to run test files directly via `node` without a dedicated CLI. It supports asynchronous tests through Promises or Node.js-style callbacks and extends the core `assert` module with additional assertions. The library prioritizes direct code execution and debuggability by not forking test processes by default, aiming to make testing feel like writing any other application code. Release cadence is infrequent, with the last major update several years ago, indicating a mature but less actively developed project. It differentiates itself by its minimalist, no-globals approach.","language":"javascript","status":"maintenance","last_verified":"Sun Apr 19","install":{"commands":["npm install node-test"],"cli":null},"imports":["const Suite = require('node-test');","suite.test('My Test', t => { /* ... */ });","t.equal(actual, expected, 'message');"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"'use strict';\nconst Suite = require('node-test');\n\nfunction funcReturnsPromise() {\n    return Promise.resolve(2);\n}\n\nfunction funcWithCallback(cb) {\n    setTimeout(cb, 10);\n}\n\nconst suite = new Suite('My Example Suite');\n\nsuite.test('Test 1 - Promise resolution', t => {\n    return funcReturnsPromise()\n        .then(result => {\n            t.equal(result, 2, 'Promise should resolve to 2');\n        });\n});\n\nsuite.test('Test 2 - Callback for async operation', (t, done) => {\n    funcWithCallback(() => {\n        t.ok(true, 'Callback should be invoked');\n        done();\n    });\n});\n\nsuite.test('Test 3 - Synchronous assertion', t => {\n    const value = 1 + 1;\n    t.equal(value, 2, '1 + 1 should equal 2');\n});\n\nsuite.skip('Test 4 - Skipped test', t => {\n    t.fail('This test should not run');\n});\n\nsuite.todo('Test 5 - Future work');","lang":"javascript","description":"Demonstrates creating a test suite, defining asynchronous tests with Promises and callbacks, synchronous assertions, and using skip/todo features.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}