From 088a948763f7a93b3579d7569f8be9784d9af0e7 Mon Sep 17 00:00:00 2001 From: Thibault Jouan Date: Sun, 5 Apr 2015 02:34:33 +0000 Subject: [PATCH] Add new cucumber remote steps --- lib/producer/core/testing/cucumber/remote_steps.rb | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/lib/producer/core/testing/cucumber/remote_steps.rb b/lib/producer/core/testing/cucumber/remote_steps.rb index 0938f61..333c59e 100644 --- a/lib/producer/core/testing/cucumber/remote_steps.rb +++ b/lib/producer/core/testing/cucumber/remote_steps.rb @@ -20,6 +20,10 @@ Then /^the remote directory "([^"]+)" must exist$/ do |path| check_directory_presence [path], true end +Then /^the remote file "([^"]+)" must exist$/ do |path| + check_file_presence [path], true +end + Then /^the remote file "([^"]+)" must contain "([^"]+)"$/ do |path, content| check_file_content path, content, true end @@ -28,6 +32,10 @@ Then /^the remote file "([^"]+)" must contain exactly "([^"]+)"$/ do |path, cont check_file_content path, content end +Then /^the remote file "([^"]+)" must contain exactly:$/ do |path, content| + check_file_content path, content +end + Then /^the remote file "([^"]+)" must match \/([^\/]+)\/$/ do |path, pattern| check_file_content path, /#{pattern}/, true end