summaryrefslogtreecommitdiff
path: root/test/dl/test_method.rb
blob: 4c104aaa04ddcc520bec185e7603b6511c9bf000 (plain)
1
2
3
4
5
6
7
8
9
10
11
require_relative 'test_base'
require 'dl/func'

module DL
  class TestMethod < TestBase
    def test_method_call
      f = Method.new(@libm['sinf'], [TYPE_FLOAT], TYPE_FLOAT)
      assert_in_delta 1.0, f.call(90 * Math::PI / 180), 0.0001
    end
  end
end