gpg_spec: use new version method to directly compare version objects
This commit is contained in:
parent
889d61660a
commit
43b64bfed1
@ -12,14 +12,12 @@ describe Gpg do
|
||||
|
||||
shutup do
|
||||
subject.create_test_key(dir)
|
||||
gpg = subject::GPG_EXECUTABLE
|
||||
@version = Utils.popen_read(gpg, "--version")[/\d\.\d/, 0]
|
||||
end
|
||||
|
||||
if @version.to_s.start_with?("2.1")
|
||||
expect(dir/".gnupg/pubring.kbx").to be_file
|
||||
if subject.version == Version.create("2.0")
|
||||
expect(dir/".gnupg/secring.gpg").to be_a_file
|
||||
else
|
||||
expect(dir/".gnupg/secring.gpg").to be_file
|
||||
expect(dir/".gnupg/pubring.kbx").to be_a_file
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user