Repository navigation
return actual name not function from _parentName - #52
Conversation
this.parent.name is a function (if defined), this.parent.pkg.name is the expected name of the package.
|
The failing test expects name to be the actual name (string). If I am right, name is the corresponding function here in ember-cli. Hence, the test is incorrect. Possible? |
Tests adjusted according to [ember-cli/lib/models/project.js](https://github.com/ember-cli/ember-cli/blob/1cae632e9724d0fc02cb91e90d83e70e78f75069/lib/models/project.js#L142).
|
Name in an addon is a property, but in a project it is a function (which is where you linked to above). |
|
@dfreeman - Would you mind reviewing this? |
rwjblue
left a comment
There was a problem hiding this comment.
We need tests for when parent is an addon and is not, are they already present?
| return this._findCoveredAddon().name; | ||
| } else { | ||
| return this.parent.name; | ||
| return this.parent.name(); |
There was a problem hiding this comment.
Aha! This seems totally correct, sorry for the misleading comments without reading the diff carefully.
There was a problem hiding this comment.
... sorry for the misleading comments regarding the commits... ;-)
|
Published as 0.3.4, thanks for your help reporting and fixing this! |
|
Tests were present, just wrong (as you found) 😣 — sorry about that! Thanks for the fix, @nfc036. |
|
Thank you for reviewing @dfreeman! |
this.parent.name is a function (if defined), this.parent.pkg.name is the expected name of the package.
Using 0.3.3 I get no coverage for any files in the app. (worked in 0.3.2)