Hi. I've added :defined in test_order method. I like that order as being consistend for me as I watch progress.
Support for testing methods with order they are defined. Added :defin…
…ed in test_order method.
Hi, I'm not sure if @zenspider will accept this feature or not, but I'm pretty sure he won't accept it if there are no tests. I think if you add tests for this pull request, it will have a much better chance of being merged.
Added test for :defined methods sort order.
Thank you @tenderlove for your comment. I've just added test covering my pull request.
While I don't see a real usecase for this, the impl and tests look good but they fail on 1.8.
My real use case is that I write tests with logical order, e. g. for controller functional tests there are four test cases in logical order: no param, empty param, wrong param, right param. Order may be random, because tests don't depend on each other, but I like to keep them in my logical order.
While it works well on ruby 1.9, you're right that it fails on 1.8.7. I made some tests and it looks to me that ruby 1.8.7 doesn't return public_instance_methods in order they are created. I think I cannot fix it on 1.8.7. If you can't find solution I think I have to back off with this pull request.
I cannot make it work in Ruby 1.8.7 so I close this pull request. I still use it in my projects with Ruby 1.9 locally. Thanks for comments @tenderlove and @zenspider .