6 ms·
That's really quite impressive! I hadn't realized that you meant that an endpoint can be referenced "in the abstract" without explicit parameters, which makes f
by mneary 12y ago
That's really quite impressive! I hadn't realized that you meant that an endpoint can be referenced "in the abstract" without explicit parameters, which makes for much easier integration.
For some reason, though, I feel like the natural language would actually intimidate me. Where are ideas like "sufficient funds" defined?
- mtamizi 12y ago"I have sufficient funds in my marketplace" is defined here: https://github.com/balanced/balanced-api/blob/master/features/step_definitions/cards.rb#L89 https://github.com/balanced/balanced-api/blob/master/feature... Given(/^I have sufficient funds in my marketplace$/) do step 'I have tokenized a card' @client.post("/cards/#{@card_id}/debits", { amount: 500000 }) end Here's another example from the scenario above: Given(/^I have a tokenized debit card$/) do @client.post('/cards', { name: "Johannes Bach", number: "4342561111111118", expiration_month: "05", expiration_year: "2015" } ) @debit_card_id = @client['cards']['id'] @client.add_hydrate(:debit_card_id, @debit_card_id) end