diff options
Diffstat (limited to 'test/openssl/test_engine.rb')
-rw-r--r-- | test/openssl/test_engine.rb | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/test/openssl/test_engine.rb b/test/openssl/test_engine.rb index 77f6e1a967..bbf56a1887 100644 --- a/test/openssl/test_engine.rb +++ b/test/openssl/test_engine.rb @@ -13,17 +13,21 @@ class OpenSSL::TestEngine < OpenSSL::TestCase def test_openssl_engine_builtin with_openssl <<-'end;' + orig = OpenSSL::Engine.engines + skip "'openssl' is already loaded" if orig.any? { |e| e.id == "openssl" } engine = OpenSSL::Engine.load("openssl") assert_equal(true, engine) - assert_equal(1, OpenSSL::Engine.engines.size) + assert_equal(1, OpenSSL::Engine.engines.size - orig.size) end; end def test_openssl_engine_by_id_string with_openssl <<-'end;' + orig = OpenSSL::Engine.engines + skip "'openssl' is already loaded" if orig.any? { |e| e.id == "openssl" } engine = get_engine assert_not_nil(engine) - assert_equal(1, OpenSSL::Engine.engines.size) + assert_equal(1, OpenSSL::Engine.engines.size - orig.size) end; end |