Preceptor 是一个测试运行器和测试聚合器,它可以平行地、连续地、组合地运行多测试和测试框架,并聚合所有测试结果和覆盖率报告。示例代码:var assert = require('assert');var lib = require('../lib');
it('should know the answer to life, the universe, and everything', function () {
assert.equal(lib.answerToLifeT
磁带运行
测试运行程序,它在(无头)浏览器中运行测试,并返回0/1作为退出代码,因此您可以将其用作npm test脚本。
用法
首先使用编写一个测试并将其保存到test/test.js :
var test = require ( 'tape' ) ;
test ( 'a test' , function ( t ) {
t . ok ( true ) ;
t . end ( ) ;
} ) ;
然后使用tape-run和运行此命令,并观看TAP结果从浏览器流进来时发生的魔力(默认值