Lines Matching refs:assert

34 const assert = require('assert');
44 assert.throws(() => {
64 assert.throws(() => {
74 assert.throws(() => {
84 assert.throws(() => {
96 assert.throws(
106 assert(list.length > 0);
111 assert.deepStrictEqual(list, sorted);
114 assert.strictEqual([...new Set(list)].length, list.length);
117 assert(list.every((value) => typeof value === 'string'));
122 assert(crypto.getCiphers().includes('aes-128-cbc'));
140 assert(tls.getCiphers().includes('aes256-sha'));
141 assert(tls.getCiphers().includes('tls_aes_128_ccm_8_sha256'));
144 assert(tlsCiphers.every((value) => noCapitals.test(value)));
148 assert.notStrictEqual(crypto.getHashes().length, 0);
149 assert(crypto.getHashes().includes('sha1'));
150 assert(crypto.getHashes().includes('sha256'));
151 assert(!crypto.getHashes().includes('SHA1'));
152 assert(!crypto.getHashes().includes('SHA256'));
153 assert(crypto.getHashes().includes('RSA-SHA1'));
154 assert(!crypto.getHashes().includes('rsa-sha1'));
161 assert.notStrictEqual(crypto.getCurves().length, 0);
162 assert(crypto.getCurves().includes('secp384r1'));
163 assert(!crypto.getCurves().includes('SECP384R1'));
172 assert.deepStrictEqual(fn(), copy);
188 // hex input that's not a power of two should throw, not assert in C++ land.
190 assert.throws(
193 assert.ok(!('opensslErrorStack' in error));
199 assert.throws(() => { throw error; }, encodingError);
205 assert.throws(
208 assert.ok(!('opensslErrorStack' in error));
209 assert.throws(() => { throw error; }, encodingError);
214 assert.throws(
217 assert.ok(!('opensslErrorStack' in error));
218 assert.throws(() => { throw error; }, encodingError);
223 assert.throws(() => {
236 assert.ok(!('opensslErrorStack' in err));
237 assert.throws(() => { throw err; }, common.hasOpenSSL3 ? {
253 assert.throws(() => {
264 assert.throws(() => { throw err; }, {
274 assert(Array.isArray(err.opensslErrorStack));
275 assert(err.opensslErrorStack.length > 0);
283 assert.throws(() => {
305 assert.strictEqual(hashValue, assertionHash);