This commit is contained in:
Andrew Mayorov 2017-05-15 17:31:10 +03:00 committed by GitHub
parent 0510e5507f
commit e8fdc1aa51
2 changed files with 14 additions and 21 deletions

View File

@ -1095,17 +1095,12 @@ default_create_contract(Config) ->
Context = ?config(context, Config),
Request = #{
<<"contractor">> => #{
<<"bankAccount">> => #{
<<"account">> => <<"testAccount">>,
<<"bankName">> => <<"testBankName">>,
<<"bankPostAccount">> => <<"testBankPostAccount">>,
<<"bankBik">> => <<"testBankBik">>
},
<<"bankAccount">> => default_bank_account(),
<<"legalEntity">> => #{
<<"entityType">> => <<"RussianLegalEntity">>,
<<"registeredName">> => <<"testRegisteredName">>,
<<"registeredNumber">> => <<"testRegisteredNumber">>,
<<"inn">> => <<"testInn">>,
<<"registeredNumber">> => <<"1234567890123">>,
<<"inn">> => <<"1234567890">>,
<<"actualAddress">> => <<"testActualAddress">>,
<<"postAddress">> => <<"testPostAddress">>,
<<"representativePosition">> => <<"testRepresentativePosition">>,
@ -1116,12 +1111,7 @@ default_create_contract(Config) ->
<<"payoutToolParams">> => #{
<<"currency">> => <<"RUB">>,
<<"payoutToolType">> => <<"PayoutToolBankAccount">>,
<<"bankAccount">> => #{
<<"account">> => <<"testAccount">>,
<<"bankName">> => <<"testBankName">>,
<<"bankPostAccount">> => <<"testBankPostAccount">>,
<<"bankBik">> => <<"testBankBik">>
}
<<"bankAccount">> => default_bank_account()
}
},
Params = #{body => Request},
@ -1181,18 +1171,21 @@ default_create_payout_tool(ContractID, Config) ->
body => #{
<<"currency">> => <<"RUB">>,
<<"payoutToolType">> => <<"PayoutToolBankAccount">>,
<<"bankAccount">> => #{
<<"account">> => <<"testAccount">>,
<<"bankName">> => <<"testBankName">>,
<<"bankPostAccount">> => <<"testBankPostAccount">>,
<<"bankBik">> => <<"testBankBik">>
}
<<"bankAccount">> => default_bank_account()
}
},
{Host, Port, PreparedParams} = api_client_lib:make_request(Context, Params),
Response = swagger_payouts_api:create_payout_tool(Host, Port, PreparedParams),
handle_response(Response).
default_bank_account() ->
#{
<<"account">> => <<"12345678901234567890">>,
<<"bankName">> => <<"testBankName">>,
<<"bankPostAccount">> => <<"12345678901234567890">>,
<<"bankBik">> => <<"123456789">>
}.
get_payout_tools(ContractID, Config) ->
Context = ?config(context, Config),
Params = #{

@ -1 +1 @@
Subproject commit c36fe0a3c48371f64fedf0cb7d6947e09acf57a3
Subproject commit 19713fc4643b4b4581f1e5fb7132975de8a6842f