Skip to content

Commit

Permalink
Commented out flaky spec that also wasn't testing what it was suppose…
Browse files Browse the repository at this point in the history
…d to.

See #2299: 'Improve FFI::Function can wrap a blocking function spec' for details.
  • Loading branch information
nirvdrum committed Dec 10, 2014
1 parent 0e60f31 commit f9fbfa7
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions spec/ffi/function_spec.rb
Expand Up @@ -63,12 +63,12 @@ class << self; self; end
end

it 'can wrap a blocking function' do
fp = FFI::Function.new(:void, [ :int ], @libtest.find_function('testBlocking'), :blocking => true)
time = Time.now
threads = []
threads << Thread.new { fp.call(2) }
threads << Thread.new(time) { expect(Time.now - time).to be < 1 }
threads.each { |t| t.join }
# fp = FFI::Function.new(:void, [ :int ], @libtest.find_function('testBlocking'), :blocking => true)
# time = Time.now
# threads = []
# threads << Thread.new { fp.call(2) }
# threads << Thread.new(time) { expect(Time.now - time).to be < 1 }
# threads.each { |t| t.join }
end

it 'autorelease flag is set to true by default' do
Expand Down

0 comments on commit f9fbfa7

Please sign in to comment.