Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
fix the osgi tests by improving the test whether posix uses native or…
… not
  • Loading branch information
mkristian committed Dec 11, 2014
1 parent 2746b56 commit 79d5675
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 20 deletions.
Expand Up @@ -78,7 +78,7 @@ public void testJRubyCreate() throws Exception {
System.err.println();

// System.setProperty( "jruby.debug.loadService", "true" );
System.setProperty( "jruby.native.verbose", "true" );
//System.setProperty( "jruby.native.enabled", "true" );

IsolatedScriptingContainer jruby = new IsolatedScriptingContainer();
jruby.addLoadPath( Scripts.class.getClassLoader() );
Expand All @@ -102,11 +102,9 @@ public void testJRubyCreate() throws Exception {
String list = (String) jruby.runScriptlet( "Gem.loaded_specs.keys.inspect" );
assertEquals(list, "[\"rake\"]");

// ensure we can load ffi
loaded = (Boolean) jruby.runScriptlet( "require 'ffi'" );
//assertEquals(true, loaded);
list = (String) jruby.runScriptlet( "Gem.loaded_specs.keys.inspect" );
assertEquals(list, "[\"rake\"]");
// ensure we have native working
loaded = (Boolean) jruby.runScriptlet( "JRuby.runtime.posix.is_native" );
assertEquals(true, loaded);

// ensure we can load openssl (with its bouncy-castle jars)
loaded = (Boolean) jruby.runScriptlet( "require 'openssl'" );
Expand Down

This file was deleted.

Expand Up @@ -83,12 +83,12 @@ public void testJRubyCreate() throws InterruptedException {
String list = (String) jruby.runScriptlet( "Gem.loaded_specs.keys.inspect" );
assertEquals(list, "[\"rake\"]");

// ensure we can load openssl (with its bouncy-castle jars)
loaded = (Boolean) jruby.runScriptlet( "require 'openssl'" );
// ensure we have native working
loaded = (Boolean) jruby.runScriptlet( "JRuby.runtime.posix.is_native" );
assertEquals(true, loaded);

// ensure we can load ffi
loaded = (Boolean) jruby.runScriptlet( "require 'ffi'" );
// ensure we can load openssl (with its bouncy-castle jars)
loaded = (Boolean) jruby.runScriptlet( "require 'openssl'" );
assertEquals(true, loaded);

String gemPath = (String) jruby.runScriptlet( "Gem::Specification.dirs.inspect" );
Expand Down

0 comments on commit 79d5675

Please sign in to comment.