This comment is hidden because it contains spoiler information about the solution
Typo in the sample tests: "Lamp getter method..." instead of "Lamp setter method..." under "// test setters"
( JS, possibly others )
Nothing is apparently being done with the colour of the lamp. I suppose there are tests, but it feels unsatisfying.
Prescribing the internal representation for on is not good. That implementation detail could, and therefore should, be hidden and up to the programmer.
Marking this as a suggestion three and a half years late would not be very useful though.
Not an issue.
If this is intended to be a beginner-level kata, perhaps the instructions/requirements could be more explicit about the constructor (order of params?) and getters/setters (method names?). New programmers may not have learned the conventions for getting and setting.
add TODO: Give the lamp an instance method called toggle_switch that will switch the value of the on attribute.
Groovy translation kumited. Please review and approve. Thanks, suic
I like that this kata tries to be simple and stay simple, even to the dismay of those who already get it and would like to move on.
my python translation (see above) fixes this issue, if it gets approved ;-)
Python translation kumited -- please review and approve.