Skip to content

Commit e7e6732

Browse files
authored
Merge pull request #708 from Gaurav0/fix_glimmer_integration_test_bugs
Fix glimmer integration test bugs
2 parents 87a3013 + 4a4a90a commit e7e6732

3 files changed

Lines changed: 29 additions & 4 deletions

File tree

app/mixins/files.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ export default Mixin.create({
114114

115115
let isGlimmer = await this.emberCli.twiddleJson.hasAddon(this.model, '@glimmer/component');
116116

117-
if (this.isPathInvalid('component', path)) {
117+
if (!isGlimmer && this.isPathInvalid('component', path)) {
118118
return;
119119
}
120120

app/mixins/test-files.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ export default Mixin.create({
5656
let openComponent = descriptor => `<${descriptor}>`;
5757
let closeComponent = descriptor => `</${descriptor}>`;
5858
let selfCloseComponent = descriptor => `<${descriptor} />`;
59-
let hbsImportStatement = `import hbs from 'htmlbars-inline-precomipile';`;
59+
let hbsImportStatement = `import hbs from 'htmlbars-inline-precompile';`;
6060

6161
const fileProperties = this.emberCli.buildProperties(blueprint, {
6262
testType: 'integration',

tests/acceptance/gist-test.js

Lines changed: 27 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ module('Acceptance | gist', function(hooks) {
149149
assert.deepEqual(columnFiles, [jsFile, hbsFile], 'Added files are displayed');
150150
});
151151

152-
test('component without hyphen fails', async function(assert) {
152+
test('ember component without hyphen fails', async function(assert) {
153153
assert.expect(2);
154154

155155
let called = false;
@@ -159,7 +159,32 @@ module('Acceptance | gist', function(hooks) {
159159
};
160160
promptValue = "components/some-dir/mycomp";
161161

162-
await visit('/');
162+
await runGist([
163+
{
164+
filename: 'application.template.hbs',
165+
content: 'hello world!'
166+
},
167+
{
168+
filename: 'twiddle.json',
169+
content: `{
170+
"version": "0.17.0",
171+
"EmberENV": {
172+
"FEATURES": {}
173+
},
174+
"options": {
175+
"use_pods": false,
176+
"enable-testing": false
177+
},
178+
"dependencies": {
179+
"jquery": "https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.js",
180+
"ember": "3.12.1",
181+
"ember-template-compiler": "3.12.1",
182+
"ember-testing": "3.12.1"
183+
},
184+
"addons": {}
185+
}`
186+
}
187+
]);
163188
await click('.add-component-link');
164189
await click(firstFilePicker());
165190
assert.ok(called, "alert was called");

0 commit comments

Comments
 (0)