Sign in verified accounts automatically and require eight-character passwords

This commit is contained in:
2026-10-13 16:33:52 +09:00
parent 9e0f493228
commit d6e60ecb3b
18 changed files with 538 additions and 63 deletions

View File

@@ -15,13 +15,13 @@ async function signed(f, client, email) {
id,
email,
displayName: email,
passwordHash: await f.service.auth.password('1234'),
passwordHash: await f.service.auth.password('12345678'),
status: 'active',
verifiedAt: Date.now(),
createdAt: Date.now(),
})
.run();
const login = await f.call(client, '/auth/login', 'POST', { email, password: '1234' });
const login = await f.call(client, '/auth/login', 'POST', { email, password: '12345678' });
assert.equal(login.statusCode, 200, login.body);
client.cookie += '; ' + String(login.headers['set-cookie']).split(';')[0];
return id;
@@ -168,7 +168,7 @@ test('기기 수신은 로그인 계정의 날짜 기록에만 자동 저장,
);
const login = await f.call(b, '/auth/login', 'POST', {
email: 'receiver@hop.test',
password: '1234',
password: '12345678',
});
b.cookie =
b.cookie.split('; hop_account=')[0] +