Sha256: 94a8244fadbb4ad9aff6dc6d3e31976d89fca36fa4b4ab4f1376a451a8718815

Contents?: true

Size: 505 Bytes

Versions: 1

Compression:

Stored size: 505 Bytes

Contents

require 'test_helper'

context "Extension with globally available functions" do

  specify "should make functions available" do
    Extension.new "functions" do |e|
      e.sources full_dir("headers/functions.h")
      e.namespace "functions"
    end

    require 'functions'

    should.not.raise NameError do
      test1
    end

    should.not.raise NameError do
      assert_in_delta 1.0, test2(2.0), 0.001
    end

    should.not.raise NameError do
      test3(2, 4.2).should == 2
    end
  end

end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
rbplusplus-0.9.1 test/functions_test.rb