Skip to content
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

Fixes #3829 #3830

Closed
wants to merge 1 commit into from
Closed

Fixes #3829 #3830

wants to merge 1 commit into from

Conversation

ghost
Copy link

@ghost ghost commented Apr 7, 2015

Fixes #3829

@ghost ghost changed the title fix failing running generate test blueprint in an addon Fixes #3829 Apr 7, 2015
@ghost
Copy link
Author

ghost commented Apr 7, 2015

This was an easy fix for me, don't have the time to add tests right now. Might have some time tomorrow. Maybe @trabus can pick it up?

@trabus
Copy link
Contributor

trabus commented Apr 7, 2015

The tests are super easy, just drop this into tests/acceptance/addon-generate-test.js at line 175

  it('in-addon component-test x-foo', function() {
    return generateInAddon(['component-test', 'x-foo']).then(function() {
      assertFile('tests/unit/components/x-foo-test.js', {
        contains: [
          "import {" + EOL +
          "  moduleForComponent," + EOL +
          "  test" + EOL +
          "} from 'ember-qunit';",
          "moduleForComponent('x-foo'"
        ]
      });
    });
  });

And this into tests/acceptance/in-repo-addon-generate-test.js at line 185

  it('in-repo-addon component-test x-foo', function() {
    return generateInRepoAddon(['component-test', 'x-foo', '--in-repo-addon=my-addon']).then(function() {
      assertFile('tests/unit/components/x-foo-test.js', {
        contains: [
          "import {" + EOL +
          "  moduleForComponent," + EOL +
          "  test" + EOL +
          "} from 'ember-qunit';",
          "moduleForComponent('x-foo'"
        ]
      });
    });
  });

@trabus
Copy link
Contributor

trabus commented Apr 8, 2015

I actually need to fix this issue for files generated into the 'server' and 'blueprints' folders, so I'm creating a PR (#3845) for that as well, which will include the fix for this issue. If you don't mind, I'm going to close this so we don't have to worry about merge conflicts. Thank you for the PR though, it's really appreciated!

@trabus trabus closed this Apr 8, 2015
@ghost ghost deleted the fix-generate-test-blueprint-in-addon branch April 8, 2015 09:55
@ghost
Copy link
Author

ghost commented Apr 8, 2015

👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

The 'component-test' blueprint does not support generating inside addons.
3 participants