| [ next ] [ prev ] [ contents ] [ up to A Real Test ] | XP-Cinti TDD Workshop |
Lets define the Net class now. We open a file named 'net.rb' and enter the following code ...
# file: net.rb class Net end |
And don't forget to add the proper require line to our test program.
# file: testnet.rb require 'test/unit' require 'net' ... |
And try our test again ...
$ ruby testnet.rb Loaded suite testnet Started... .. Error occurred in test_untied(TestNet): NameError: undefined method `untied?' for #<Net:0x40216a60> testnet.rb:7:in `test_untied' testnet.rb:5 Finished in 0.051946 seconds. 1 runs, 0 assertions, 0 failures, 1 errors |
Now the test is complaining that the method untied? is not defined.
It looks like our next job is to write a new method.
| [ next ] [ prev ] [ contents ] [ up to A Real Test ] | Copyright 2003 by Jim Weirich.![]() |