Node.js 学习记录 -- 02Assertion Testing( 断言测试 )

  1.assert(value[, message])

  2.assert.deepEqual(actual, expected[, message])

  3.assert.deepStrictEqual(actual, expected[, message])

  4.assert.doesNotThrow(block[, error][, message])

  5.assert.equal(actual, expected[, message])

  6.assert.fail(message)

  7.assert.fail(actual, expected[, message[, operator[, stackStartFunction]]])

  8.assert.ifError(value)

  9.assert.notDeepEqual(actual, expected[, message])

  10.assert.notDeepStrictEqual(actual, expected[, message])

  11.assert.notEqual(actual, expected[, message])

  12.assert.notStrictEqual(actual, expected[, message])

  13.assert.ok(value[, message])

  14.assert.strictEqual(actual, expected[, message])

  15.assert.throws(block[, error][, message])

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:https://www.heiqu.com/zyzwwf.html