[era features] Added tests to check that dump/restore is a noop

This commit is contained in:
Joe Thornber 2014-09-01 14:45:52 +01:00
parent 4c04a18b05
commit 562661c63e
2 changed files with 19 additions and 0 deletions

View File

@ -82,3 +82,14 @@ Feature: era_restore
"""
"""
Scenario: dump/restore is a noop
Given valid era metadata
When I era dump
And I era restore
And I era dump
Then dumps 1 and 2 should be identical
Scenario: dump matches original metadata
Given valid era metadata
When I era dump
Then dumps 0 and 1 should be identical

View File

@ -37,3 +37,11 @@ Given(/^valid era metadata$/) do
run_simple("era_restore -i #{xml_file} -o #{dev_file}")
end
When(/^I era dump$/) do
run_simple("era_dump #{dev_file} -o #{new_dump_file}", true)
end
When(/^I era restore$/) do
run_simple("era_restore -i #{dump_files[-1]} -o #{dev_file}", true)
end