-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Provide an option to use dasherized test names #14915
Comments
I tend to agree that this is confusing default behavior and I often hand edit the name myself because the humanizer invented some bad looking name for the component or module. For a |
@GabrielCW perhaps this is an issue that belongs on the ember-cli project instead of the ember.js project. The blueprints are part of https://github.com/ember-cli/ember-cli/issues |
@pixelhandler they shouldn't be? https://github.com/emberjs/ember.js/tree/master/blueprints |
agreed, the relevant blueprints for this issue live in ember.js and ember-data now and that is where they should be discussed. |
@locks oh forgot, they used to live in ember-cli, my bad. |
@Turbo87 @GabrielCW @locks - I'm curious if this should be discussed on an RFC issue instead of in two places ember.js and data issue trackers.
|
@pixelhandler I'm not sure if this would actually need a full blown RFC to be honest, but feel free to write one 😉 |
@pixelhandler @Turbo87 I went ahead and wrote the RFC, it is available here. |
@GabrielCW awesome, thanks! |
When tests are generated, there name is humanized to make it more readable by humans. This process removes the dashes from the base strings, meaning
some-component
's test name will besome component
.I recently had a problem where I couldn't run test for one of my components with
ember test --filter="some-component"
. To make it more confusing, jshint tests ran well for the expected files, but the test itself didn't run. @Turbo87 helped me figure out it was because the test name wassome component
, therefore not matchingsome-component
.Considering the test's name is humanized, it was counter intuitive to think that it may be used in resolution.
Could an option be added to the generator, in order to allow for the string to stay dasherized? With that option, a test generated for
some-name/space/some-component
would actually containsome-name/space/some-component
.Or could it even be used as default? Is the current humanized form relied upon?
The text was updated successfully, but these errors were encountered: