Fix tests on Windows

This commit is contained in:
Lars Kanis 2018-03-13 16:56:14 +01:00
parent 257b1a5e49
commit 6c143d74c2

View File

@ -22,7 +22,7 @@ class TestPgLdapSync < Minitest::Test
unless $?.success?
$stderr.puts "Command failed: [%s]\n%s" % [cmd.join(' '), File.read(fname)]
end
File.unlink fname
File.unlink fname rescue nil # File is locked on Windows
raise "Command failed: [%s]" % [cmd.join(' ')] unless $?.success?
end
end