diff options
author | Azul <azul@riseup.net> | 2018-01-15 18:21:44 +0100 |
---|---|---|
committer | Azul <azul@riseup.net> | 2018-01-18 16:43:23 +0100 |
commit | b8ba4f27a82868e0b3338b4af761f7c44226e729 (patch) | |
tree | 45b495e18bab72508342b86cd42ab3d56ed1eacc /features/step_definitions/api_steps.rb | |
parent | fd2fc85c2daf60605641cc582d75134a10e7b4a4 (diff) |
(WIP) first steps towards implementing keys API
Diffstat (limited to 'features/step_definitions/api_steps.rb')
-rw-r--r-- | features/step_definitions/api_steps.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/features/step_definitions/api_steps.rb b/features/step_definitions/api_steps.rb index 7188694..7b73272 100644 --- a/features/step_definitions/api_steps.rb +++ b/features/step_definitions/api_steps.rb @@ -37,7 +37,7 @@ When /^I digest\-authenticate as the user "(.*?)" with the password "(.*?)"$/ do digest_authorize user, pass end -When /^I (?:have sent|send) a (GET|POST|PUT|DELETE) request (?:for|to) "([^"]*)"(?: with the following:)?$/ do |*args| +When /^I (?:have sent|send) a (GET|POST|PUT|DELETE|PATCH) request (?:for|to) "([^"]*)"(?: with the following:)?$/ do |*args| request_type = args.shift path = args.shift input = args.shift @@ -45,7 +45,7 @@ When /^I (?:have sent|send) a (GET|POST|PUT|DELETE) request (?:for|to) "([^"]*)" request_opts = {method: request_type.downcase.to_sym} unless input.nil? - if input.class == Cucumber::Ast::Table + if input.class == Cucumber::MultilineArgument::DataTable request_opts[:params] = input.rows_hash else request_opts[:input] = input |