Compare commits

...

4 Commits

Author SHA1 Message Date
c641a0c669
add api failure nodes 2024-10-14 23:19:09 +03:00
952da86931
update balance nodes 2024-10-14 23:18:42 +03:00
be6391686f
update return type 2024-10-14 23:17:57 +03:00
65794c1b20
add api calls flag 2024-10-14 23:17:17 +03:00
8 changed files with 29 additions and 10 deletions

View File

@ -15,12 +15,12 @@ func (m *MockAccountService) CreateAccount() (*models.AccountResponse, error) {
return args.Get(0).(*models.AccountResponse), args.Error(1)
}
func (m *MockAccountService) CheckBalance(publicKey string) (string, error) {
func (m *MockAccountService) CheckBalance(publicKey string) (*models.BalanceResponse, error) {
args := m.Called(publicKey)
return args.String(0), args.Error(1)
return args.Get(0).(*models.BalanceResponse), args.Error(1)
}
func (m *MockAccountService) CheckAccountStatus(trackingId string) (string, error) {
func (m *MockAccountService) CheckAccountStatus(trackingId string) (*models.TrackStatusResponse, error) {
args := m.Called(trackingId)
return args.String(0), args.Error(1)
return args.Get(0).(*models.TrackStatusResponse), args.Error(1)
}

View File

@ -0,0 +1 @@
Failed to connect to the custodial service.Please try again.

View File

@ -0,0 +1,5 @@
MOUT retry 0
MOUT quit 9
HALT
INCMP _ 0
INCMP quit 9

View File

@ -1 +1 @@
Your community balance is: 0.00SRF
{{.fetch_custodial_balances}}

View File

@ -1,5 +1,11 @@
LOAD reset_incorrect 0
LOAD reset_incorrect 6
LOAD fetch_custodial_balances 0
CATCH api_failure flag_api_call_error 1
MAP fetch_custodial_balances
CATCH incorrect_pin flag_incorrect_pin 1
CATCH pin_entry flag_account_authorized 0
LOAD quit_with_balance 0
MOUT back 0
MOUT quit 9
HALT
INCMP _ 0
INCMP quit 9

View File

@ -1 +1 @@
Your balance is: 0.00 SRF
{{.fetch_custodial_balances}}

View File

@ -1,5 +1,11 @@
LOAD reset_incorrect 0
LOAD reset_incorrect 6
LOAD fetch_custodial_balances 0
CATCH api_failure flag_api_call_error 1
MAP fetch_custodial_balances
CATCH incorrect_pin flag_incorrect_pin 1
CATCH pin_entry flag_account_authorized 0
LOAD quit_with_balance 0
MOUT back 0
MOUT quit 9
HALT
INCMP _ 0
INCMP quit 9

View File

@ -14,3 +14,4 @@ flag,flag_valid_pin,20,this is set when the given PIN is valid
flag,flag_allow_update,21,this is set to allow a user to update their profile data
flag,flag_single_edit,22,this is set to allow a user to edit a single profile item such as year of birth
flag,flag_incorrect_date_format,23,this is set when the given year of birth is invalid
flag,flag_api_call_error,25,this is set when communication to an external service fails

1 flag flag_language_set 8 checks whether the user has set their prefered language
14 flag flag_allow_update 21 this is set to allow a user to update their profile data
15 flag flag_single_edit 22 this is set to allow a user to edit a single profile item such as year of birth
16 flag flag_incorrect_date_format 23 this is set when the given year of birth is invalid
17 flag flag_api_call_error 25 this is set when communication to an external service fails