Created
August 13, 2012 13:11
-
-
Save misfo/3340587 to your computer and use it in GitHub Desktop.
testing module functions in Ruby
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Funcs | |
module_function | |
# functions ... | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'minitest/autorun' | |
class FuncsTest < MiniTest::Unit::TestCase | |
# ensures none of the methods tested set or mutate instance variables | |
Funcs = ::Funcs.dup.freeze | |
# tests | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment