From 31b64c4de7d22fd465a28180ad03ab7d1054883b Mon Sep 17 00:00:00 2001 From: Matthias Beyer Date: Fri, 20 Jan 2017 10:38:06 +0100 Subject: [PATCH] Add mini test example --- imag-ruby/test/test_store_id_load.rb | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 imag-ruby/test/test_store_id_load.rb diff --git a/imag-ruby/test/test_store_id_load.rb b/imag-ruby/test/test_store_id_load.rb new file mode 100644 index 00000000..9d46ab01 --- /dev/null +++ b/imag-ruby/test/test_store_id_load.rb @@ -0,0 +1,11 @@ +#!/usr/bin/env ruby + +require 'fiddle' + +lib = Fiddle::dlopen './target/debug/libimag_ruby.so' +Fiddle::Function::new(lib['imag_ruby_initialize'], [], Fiddle::TYPE_VOIDP).call + +works = (not RStoreId.new_baseless("test").nil?) + +puts "Works: #{works}" +