Skip to content

Commit 6a34dc8

Browse files
committed
Mock captcha_required endpoint
1 parent 14e7ff7 commit 6a34dc8

2 files changed

Lines changed: 7 additions & 1 deletion

File tree

test/helpers/helpers.mock-rest-v2.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,14 +51,16 @@ const getMockDataOpts = () => ({
5151
login: null,
5252
login_verify: null,
5353
captcha_providers: null,
54+
captcha_required: null,
5455
platform_status: null
5556
})
5657

5758
const getExtraMockMethods = () => (new Map([
5859
['post', {
5960
'/v2/login': 'login',
6061
'/v2/login/verify': 'login_verify',
61-
'/v2/int/captcha/providers': 'captcha_providers'
62+
'/v2/int/captcha/providers': 'captcha_providers',
63+
'/v2/int/captcha/required': 'captcha_required'
6264
}]
6365
]))
6466

test/helpers/mock-data.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,10 @@ module.exports = new Map([
2929
'captcha_providers',
3030
['hcaptcha']
3131
],
32+
[
33+
'captcha_required',
34+
true
35+
],
3236
[
3337
'generate_token',
3438
['pub:api:88888888-4444-4444-4444-121212121212-caps:s:o:f:w:wd:a-write']

0 commit comments

Comments
 (0)