Skip to content

Instantly share code, notes, and snippets.

@paneq
Created December 13, 2010 10:55
Show Gist options
  • Save paneq/738889 to your computer and use it in GitHub Desktop.
Save paneq/738889 to your computer and use it in GitHub Desktop.
require 'minitest/unit'
MiniTest::Unit.autorun
class TestMeme < MiniTest::Unit::TestCase
def test_flunk
pid = fork do
exec("sleep 100") # firefox in reality
end
at_exit do
begin
::Process.kill "TERM", pid
raise "blah"
rescue
sleep 2
::Process.kill "KILL", pid
sleep 2
end
end
flunk("no reason")
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment