Uh oh!
There was an error while loading. Please reload this page.
Done(Panda, Tiger, Eagle) - #14
Open
var114 wants to merge 11 commits into
Open
Conversation
Member
There was a problem hiding this comment.
In RSpec, it has cool matchers that I like to point out. You could rewrite this methot as:
Vehicle.wheels.shouldbe_niljwo
commented
Nov 19, 2013
Member
Looks pretty great! The only thing I wasn't 100% on was the classVehicle@@wheels=0defself.wheels@@wheelsendendThen in your motorcycle, you can override the classMotorcylcle < Vehicle@@wheels=2endVehicle.wheels=>0Motorcycle.wheels=>2OR, possibly event simpler (but without using class variables):classVehicleWHEEL_COUNT=0defself.wheelsWHEEL_COUNTendendclassMotorcycle < VehicleWHEEL_COUNT=2endputsMotorcycle.wheels=>2 |
This file contains hidden or 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
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.