Created
June 12, 2012 22:37
-
-
Save matthuhiggins/2920554 to your computer and use it in GitHub Desktop.
test time tracker
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
@@test_classes = {} | |
@@test_methods = {} | |
setup do | |
@start_time = Time.now | |
end | |
teardown do | |
delta = Time.now - @start_time | |
@@test_classes[self.class.name] ||= 0 | |
@@test_classes[self.class.name] += delta | |
@@test_methods["#{self.class.name}##{method_name}"] = delta | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment