Unverified Commit c9292022 authored by intrigeri's avatar intrigeri
Browse files

Test suite: record old version when installing one to disk

This will allow us, in some cases, to avoid doing the
"disable USE_LAST_RELEASE_AS_OLD_ISO until next release,
then re-enable it" dance: test suite code can behave differently
depending on $old_version.
parent 0c7a111a
......@@ -1276,6 +1276,17 @@ Then(/^the layout of the screen keyboard is set to "([^"]+)"$/) do |layout|
end
Given /^I write (|an old version of )the Tails (ISO|USB) image to disk "([^"]+)"$/ do |old, type, name|
if old != ''
match = /^tails-amd64-(\d+[.]\d+(?:[.]\d+)?)[.]img$/
.match(File.basename(OLD_TAILS_IMG))
$old_version = match.nil? ? nil : match[1]
if $old_version.nil?
debug_log('Failed to extract old version. This is expected, and OK,' \
'if you passed anything but a stable release to --old-iso')
else
debug_log("Old version: #{$old_version}")
end
end
src_disk = {
path: (if old == ''
type == 'ISO' ? TAILS_ISO : TAILS_IMG
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment