Skip to content

Commit

Permalink
Use explicit this in helper-test blueprints
Browse files Browse the repository at this point in the history
  • Loading branch information
bertdeblock committed May 13, 2021
1 parent ac201b8 commit 844c2f4
Show file tree
Hide file tree
Showing 10 changed files with 10 additions and 10 deletions.
Expand Up @@ -19,7 +19,7 @@ describe('<%= friendlyTestName %>', function() {
// `);
this.set('inputValue', '1234');

this.render(hbs`{{<%= dasherizedModuleName %> inputValue}}`);
this.render(hbs`{{<%= dasherizedModuleName %> this.inputValue}}`);

expect(this.$().text().trim()).to.equal('1234');
});
Expand Down
Expand Up @@ -19,7 +19,7 @@ describeComponent('<%= dasherizedModuleName %>', 'helper:<%= dasherizedModuleNam
// `);
this.set('inputValue', '1234');

this.render(hbs`{{<%= dasherizedModuleName %> inputValue}}`);
this.render(hbs`{{<%= dasherizedModuleName %> this.inputValue}}`);

expect(this.$().text().trim()).to.equal('1234');
});
Expand Down
Expand Up @@ -11,7 +11,7 @@ describe('<%= friendlyTestName %>', function() {
it('renders', async function() {
this.set('inputValue', '1234');

await render(hbs`{{<%= dasherizedModuleName %> inputValue}}`);
await render(hbs`{{<%= dasherizedModuleName %> this.inputValue}}`);

expect(this.element.textContent.trim()).to.equal('1234');
});
Expand Down
Expand Up @@ -9,7 +9,7 @@ moduleForComponent('<%= dasherizedModuleName %>', 'helper:<%= dasherizedModuleNa
test('it renders', function(assert) {
this.set('inputValue', '1234');

this.render(hbs`{{<%= dasherizedModuleName %> inputValue}}`);
this.render(hbs`{{<%= dasherizedModuleName %> this.inputValue}}`);

assert.equal(this.$().text().trim(), '1234');
});<% } else if (testType == 'unit') { %>
Expand Down
Expand Up @@ -10,7 +10,7 @@ module('<%= friendlyTestName %>', function(hooks) {
test('it renders', async function(assert) {
this.set('inputValue', '1234');

await render(hbs`{{<%= dasherizedModuleName %> inputValue}}`);
await render(hbs`{{<%= dasherizedModuleName %> this.inputValue}}`);

assert.dom(this.element).hasText('1234');
});
Expand Down
2 changes: 1 addition & 1 deletion node-tests/fixtures/helper-test/integration.js
Expand Up @@ -9,7 +9,7 @@ moduleForComponent('foo/bar-baz', 'helper:foo/bar-baz', {
test('it renders', function(assert) {
this.set('inputValue', '1234');

this.render(hbs`{{foo/bar-baz inputValue}}`);
this.render(hbs`{{foo/bar-baz this.inputValue}}`);

assert.equal(this.$().text().trim(), '1234');
});
2 changes: 1 addition & 1 deletion node-tests/fixtures/helper-test/mocha-0.12.js
Expand Up @@ -19,7 +19,7 @@ describe('Integration | Helper | foo/bar-baz', function() {
// `);
this.set('inputValue', '1234');

this.render(hbs`{{foo/bar-baz inputValue}}`);
this.render(hbs`{{foo/bar-baz this.inputValue}}`);

expect(this.$().text().trim()).to.equal('1234');
});
Expand Down
2 changes: 1 addition & 1 deletion node-tests/fixtures/helper-test/mocha-rfc232.js
Expand Up @@ -11,7 +11,7 @@ describe('Integration | Helper | foo/bar-baz', function() {
it('renders', async function() {
this.set('inputValue', '1234');

await render(hbs`{{foo/bar-baz inputValue}}`);
await render(hbs`{{foo/bar-baz this.inputValue}}`);

expect(this.element.textContent.trim()).to.equal('1234');
});
Expand Down
2 changes: 1 addition & 1 deletion node-tests/fixtures/helper-test/mocha.js
Expand Up @@ -19,7 +19,7 @@ describeComponent('foo/bar-baz', 'helper:foo/bar-baz',
// `);
this.set('inputValue', '1234');

this.render(hbs`{{foo/bar-baz inputValue}}`);
this.render(hbs`{{foo/bar-baz this.inputValue}}`);

expect(this.$().text().trim()).to.equal('1234');
});
Expand Down
2 changes: 1 addition & 1 deletion node-tests/fixtures/helper-test/rfc232.js
Expand Up @@ -10,7 +10,7 @@ module('Integration | Helper | foo/bar-baz', function(hooks) {
test('it renders', async function(assert) {
this.set('inputValue', '1234');

await render(hbs`{{foo/bar-baz inputValue}}`);
await render(hbs`{{foo/bar-baz this.inputValue}}`);

assert.dom(this.element).hasText('1234');
});
Expand Down

0 comments on commit 844c2f4

Please sign in to comment.