Skip to content

Commit

Permalink
Added a link to the deprecations warning to point to a codemod to hel…
Browse files Browse the repository at this point in the history
…p address it (#140)

The codemod is here: https://github.com/lorcan/test-selectors-codemod
  • Loading branch information
lorcan authored and marcoow committed Aug 30, 2017
1 parent 594abd0 commit a521f69
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,12 @@ was triggered by `ember test`. That means that if you use
`ember test --environment=production` the test selectors will still work, but
for `ember build -prod` they will be stripped out.

Deprecations
------------------------------------------------------------------------------

The `testSelector` helper was deprecated in [v0.3.7](https://github.com/simplabs/ember-test-selectors/releases/tag/v0.3.7).
There's a codemod available at https://github.com/lorcan/test-selectors-codemod
that can help make the necessary transformations to address the deprecation.

License
------------------------------------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion addon/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ export default function testSelector(key, value) {
deprecate(message, false, {
id: 'ember-test-selectors.test-selector-helper',
until: '0.4.0',
url: 'https://github.com/simplabs/ember-test-selectors#usage',
url: 'https://github.com/simplabs/ember-test-selectors#deprecations',
});

return isNone(value) ? `[data-test-${key}]` : `[data-test-${key}="${value}"]`;
Expand Down

0 comments on commit a521f69

Please sign in to comment.