|
|
@ -412,6 +412,11 @@ describe('authentication', function () {
|
|
|
|
},
|
|
|
|
},
|
|
|
|
function (res, body, jar, next) {
|
|
|
|
function (res, body, jar, next) {
|
|
|
|
meta.config.loginAttempts = 5;
|
|
|
|
meta.config.loginAttempts = 5;
|
|
|
|
|
|
|
|
assert.equal(res.statusCode, 403);
|
|
|
|
|
|
|
|
assert.equal(body, '[[error:account-locked]]');
|
|
|
|
|
|
|
|
loginUser('lockme', 'abcdef', next);
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
function (res, body, jar, next) {
|
|
|
|
assert.equal(res.statusCode, 403);
|
|
|
|
assert.equal(res.statusCode, 403);
|
|
|
|
assert.equal(body, '[[error:account-locked]]');
|
|
|
|
assert.equal(body, '[[error:account-locked]]');
|
|
|
|
db.exists('lockout:' + uid, next);
|
|
|
|
db.exists('lockout:' + uid, next);
|
|
|
|