Skip to content

Commit

Permalink
test(deriv_passkeys): added mock data passkeysListResponse
Browse files Browse the repository at this point in the history
  • Loading branch information
bassam-deriv committed Mar 20, 2024
1 parent 93ac618 commit 2a0b3b5
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/services/connection/api_manager/mock_api.dart
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import 'package:flutter_deriv_api/services/connection/api_manager/connection_inf
import 'package:flutter_deriv_api/services/connection/api_manager/exceptions/api_manager_exception.dart';
import 'package:flutter_deriv_api/services/connection/api_manager/mock_data/account/new_account_wallet_response.dart';
import 'package:flutter_deriv_api/services/connection/api_manager/mock_data/cashier/cashier_payments_response.dart';
import 'package:flutter_deriv_api/services/connection/api_manager/mock_data/passkeys/passkeys_list_response.dart';
import 'package:flutter_deriv_api/services/connection/api_manager/mock_data/passkeys/passkeys_register_options_response.dart';
import 'package:flutter_deriv_api/services/connection/api_manager/mock_data/passkeys/passkeys_register_response.dart';
import 'package:flutter_deriv_api/services/connection/call_manager/base_call_manager.dart';
Expand Down Expand Up @@ -381,6 +382,8 @@ class MockAPI extends BaseAPI {
return passkeysRegisterOptionsResponse;
case 'passkeys_register':
return passkeysRegisterResponse;
case 'passkeys_list':
return passkeysListResponse;

default:
throw APIManagerException(
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
/// Wallet migration response mock data.
const String passkeysListResponse = '''{
"echo_req": {
"passkeysList": 1
},
"msg_type": "passkeysList",
"passkeysList": [
{
"created_at": 10000,
"id": "id",
"last_used": 10000,
"name": "Passkey",
"passkey_id": "passkeyId",
"stored_on": "storedOn"
}
]
}''';

0 comments on commit 2a0b3b5

Please sign in to comment.