Joined May 2011
·
Posted to
Use Emacs/Readline Key Bindings in OS X
over 1 year
ago
SO MUCH CTRL
Posted to
Move back to the last visited directory
over 1 year
ago
if using zsh, it's even faster. all you need is the -
Achievements
324 Karma
13,999 Total ProTip Views
Kona
Have at least one original repo where CoffeeScript is the dominant language
Komodo Dragon
Have at least one original repo where Java is the dominant language
Altruist
Increase developer well-being by sharing at least 20 open source projects
Octopussy
Have a repo followed by a member of the GitHub team
Bear
Have at least one original repo where Objective-C is the dominant language
Honey Badger
Have at least one original Node.js-specific repo
Mongoose 3
Have at least three original repos where Ruby is the dominant language
Mongoose
Have at least one original repo where Ruby is the dominant language
Walrus
The walrus is no stranger to variety. Use at least 4 different languages throughout all your repos
Forked
Have a project valued enough to be forked by someone else
Charity
Fork and commit to someone's open source project in need
Why are you testing assignment at all? I assume that
set_start_date = '01/02/2012'
is actually supposed to beset_start_date('01/02/2012')
? Or maybestart_date = '01/02/2012'
Assignment is a language construct and so I would assume it to be correct and thus not worth testing. If you're overriding the assignment operator, I think that's sort of a bad idea because of this problem. I would assume from the code that:
Would be true... I realize Rails does this all the time, but I think it's bad practice and should be avoided for clarity. Otherwise I agree with the point: "us[ing] that method in both the test and the spec, you're certain it is getting set, but it might be getting set one month off without you realizing it."