diff --git a/features/cache_restore.feature b/features/cache_restore.feature index 7008966..c9121ce 100644 --- a/features/cache_restore.feature +++ b/features/cache_restore.feature @@ -86,14 +86,16 @@ Feature: cache_restore Scenario: --quiet is accepted Given valid cache metadata When I run cache_restore with -i metadata.xml -o metadata.bin --quiet - Then it should pass with: + Then it should pass + And the output should contain exactly: """ """ Scenario: -q is accepted Given valid cache metadata When I run cache_restore with -i metadata.xml -o metadata.bin -q - Then it should pass with: + Then it should pass + And the output should contain exactly: """ """ diff --git a/features/era_restore.feature b/features/era_restore.feature index 22f002c..57282f6 100644 --- a/features/era_restore.feature +++ b/features/era_restore.feature @@ -69,14 +69,16 @@ Feature: era_restore Scenario: --quiet is accepted Given valid era metadata When I run era_restore with -i metadata.xml -o metadata.bin --quiet - Then it should pass with: + Then it should pass + And the output should contain exactly: """ """ Scenario: -q is accepted Given valid era metadata When I run era_restore with -i metadata.xml -o metadata.bin -q - Then it should pass with: + Then it should pass + And the output should contain exactly: """ """ diff --git a/features/step_definitions/cache_steps.rb b/features/step_definitions/cache_steps.rb index a0343cc..48ff915 100644 --- a/features/step_definitions/cache_steps.rb +++ b/features/step_definitions/cache_steps.rb @@ -80,9 +80,9 @@ end Given(/^valid cache metadata$/) do in_current_dir do system("cache_xml create --nr-cache-blocks uniform[1000..5000] --nr-mappings uniform[500..1000] > #{xml_file}") + system("dd if=/dev/zero of=#{dev_file} bs=4k count=1024 > /dev/null") end - run_simple("dd if=/dev/zero of=#{dev_file} bs=4k count=1024") run_simple("cache_restore -i #{xml_file} -o #{dev_file}") end diff --git a/features/step_definitions/era_steps.rb b/features/step_definitions/era_steps.rb index 42aa3b0..2e6bc0a 100644 --- a/features/step_definitions/era_steps.rb +++ b/features/step_definitions/era_steps.rb @@ -32,8 +32,8 @@ end Given(/^valid era metadata$/) do in_current_dir do system("era_xml create --nr-blocks 100 --nr-writesets 2 --current-era 1000 > #{xml_file}") + system("dd if=/dev/zero of=#{dev_file} bs=4k count=1024 > /dev/null") end - run_simple("dd if=/dev/zero of=#{dev_file} bs=4k count=1024") run_simple("era_restore -i #{xml_file} -o #{dev_file}") end diff --git a/features/step_definitions/thin_steps.rb b/features/step_definitions/thin_steps.rb index d6674a6..1900293 100644 --- a/features/step_definitions/thin_steps.rb +++ b/features/step_definitions/thin_steps.rb @@ -1,9 +1,9 @@ Given(/^valid thin metadata$/) do in_current_dir do system("thinp_xml create --nr-thins uniform[4..9] --nr-mappings uniform[1000..10000] > #{xml_file}") + system("dd if=/dev/zero of=#{dev_file} bs=4k count=1024 > /dev/null") end - run_simple("dd if=/dev/zero of=#{dev_file} bs=4k count=1024") run_simple("thin_restore -i #{xml_file} -o #{dev_file}") end diff --git a/features/thin_restore.feature b/features/thin_restore.feature index 036daf7..e5bdb04 100644 --- a/features/thin_restore.feature +++ b/features/thin_restore.feature @@ -58,14 +58,16 @@ Feature: thin_restore Scenario: --quiet is accepted Given valid thin metadata When I run thin_restore with -i metadata.xml -o metadata.bin --quiet - Then it should pass with: + Then it should pass + And the output should contain exactly: """ """ Scenario: -q is accepted Given valid thin metadata When I run thin_restore with -i metadata.xml -o metadata.bin -q - Then it should pass with: + Then it should pass + And the output should contain exactly: """ """