This sounds... strange to me. When would this be an advantage over some sort of named test? e.g. `manage.py test Thing.validation_test`
This sounds... strange to me. When would this be an advantage over some sort of named test? e.g. `manage.py test Thing.validation_test`
Never. "Line number" is very obscure and prone to breaking. "I just added a comment at the top of the file... Whoops! Broke all the tests."
To quote the Zen Of Python—"explicit is better than implicit".
The article is a bit old so I wonder if that is still a common Ruby practice (if it ever was).
The only time I've ever run specific tests by line-number is when I am working on making that single test green. In cases like that the line-number hardly ever changes (if it does, its because I've modified before filters or added a new `let`).
edit: for a bit more context: that entire string would not be typed in for the single test, it would be built from contexts.
describe User do
context "belongs to a valid and paid account" do
it "should allow creation of projects" do
end
end
end