Skip to content

Instantly share code, notes, and snippets.

@AntelopeSalad
Last active August 29, 2015 13:56
Show Gist options
  • Save AntelopeSalad/9006451 to your computer and use it in GitHub Desktop.
Save AntelopeSalad/9006451 to your computer and use it in GitHub Desktop.
# I noticed this syntax worked for multiple levels of modules so I tried it
module MiniTest::Assertions
def assert_something_amazing
true
end
end
# test/integration/foo_test.rb
require '../test_helper'
class TestShell < Foo::Test::IntegrationTestCase
def test_something_cool
assert some_method
end
end
# test/test_helper.rb
require 'minitest/autorun'
$:.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
$:.unshift(File.dirname(__FILE__))
require 'assertions'
module Foo
module Test
class IntegrationTestCase < Minitest::Test
def some_method
true
end
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment