nav tabs on admin dashboard

This commit is contained in:
2019-03-07 00:20:34 -06:00
parent f73d6ae228
commit e4f473f376
11661 changed files with 216240 additions and 1544253 deletions

View File

@@ -2,6 +2,7 @@
/* global describe it */
var assert = require('assert');
var crypto = require('crypto');
var hash = require('../');
describe('Hash', function() {
@@ -121,4 +122,19 @@ describe('Hash', function() {
]
]);
});
it('handles utf8 in strings just like crypto', function() {
const algorithm = 'sha256';
test(hash[algorithm], [
'hello', // one byte per character
'привет', // two bytes per character
'您好', // three bytes per character
'👋', // four bytes per character
'hello привет 您好 👋!!!' // mixed character lengths
].map(str => [str, crypto
.createHash(algorithm)
.update(str)
.digest('hex')]));
});
});