mirror of
https://github.com/seejohnrun/haste-server.git
synced 2024-11-25 05:51:22 +00:00
Update some es6
This commit is contained in:
parent
e4e025f67e
commit
40f1f2588e
1 changed files with 5 additions and 5 deletions
|
@ -4,15 +4,15 @@ const assert = require('assert');
|
||||||
|
|
||||||
const Generator = require('../../lib/key_generators/random');
|
const Generator = require('../../lib/key_generators/random');
|
||||||
|
|
||||||
describe('RandomKeyGenerator', function() {
|
describe('RandomKeyGenerator', () => {
|
||||||
describe('randomKey', function() {
|
describe('randomKey', () => {
|
||||||
it('should return a key of the proper length', function() {
|
it('should return a key of the proper length', () => {
|
||||||
var gen = new Generator();
|
const gen = new Generator();
|
||||||
assert.equal(6, gen.createKey(6).length);
|
assert.equal(6, gen.createKey(6).length);
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should use a key from the given keyset if given', () => {
|
it('should use a key from the given keyset if given', () => {
|
||||||
var gen = new Generator({keyspace: 'A'});
|
const gen = new Generator({keyspace: 'A'});
|
||||||
assert.equal('AAAAAA', gen.createKey(6));
|
assert.equal('AAAAAA', gen.createKey(6));
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue