bin/generator: Fix outstanding TODOs#540
Conversation
|
|
||
| def test_get_binding | ||
| subject = TemplateValues.new(sha1: nil,version: nil, test_cases: nil) | ||
| subject = TemplateValues.new(abbreviated_commit_hash: nil,version: nil, test_cases: nil) |
There was a problem hiding this comment.
What's causing the lack of space in nil,version?
There was a problem hiding this comment.
xruby using a rubocop.yml with all the useful cops disabled.
There was a problem hiding this comment.
hehe, I think that is allowing it, rather than causing it. I like adding in that one. If you would like to run with a "custom" rubocop configuration, you can...
rubocop -c ~/.sane_rubocop.yml
There was a problem hiding this comment.
Well then I guess what caused it was me not hitting the spacebar between , and v.
If it's important (which it seems to be, if you're noticing it in a code review.) it should be checked for by the xruby Rubocop configuration and not rely on a different unmaintained configuration file.
There was a problem hiding this comment.
I am noticing it by sight, rather than by tool, they stand out to me.
The point of me mentioning the custom configuration is not as a solution to this, but in the use of that for individual contributors, for spotting the things that they care about... mentioning it here and hopefully having those things that are deemed important enough to come into the configuration here.
I like how this rubocop change happened here. Naturally happening, and as needed.
The responsibility for maintaining the template version belongs with the generator, not the template.
Once the templates have been updated, we no longer need to compensate for their version incrementing.
The common requirements now live in the `lib/exercise_cases.rb` file and this is included by the individual cases files rather than being loaded by the generator code.
ee57e85 to
7c7e32b
Compare
|
Rebased to resolve merge conflict. |
This patch addresses the outstanding TODOs in the recent generator refactor.
Changes all
exercise.ttfiles:sha1toabbreviated_commit_hashChanges all
lib/*_cases.rbfiles:requires out of the generator.I was initially planning on doing this as 3 Pull Requests, but the default git settings weren't quite clever enough to work out how to merge the independent changes without conflicts so I've applied them all in one PR. The individual commits show the independent steps.