@ember/app-blueprint 0.8.2 → 6.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (61) hide show
  1. package/.prettierignore +1 -2
  2. package/.release-plan.json +9 -5
  3. package/CHANGELOG.md +17 -0
  4. package/eslint.config.mjs +1 -5
  5. package/files/package.json +43 -43
  6. package/package.json +2 -2
  7. package/tests/arguments.test.mjs +155 -0
  8. package/tests/fixtures/tests-js-10/app/components/.gitkeep +0 -0
  9. package/tests/fixtures/tests-js-10/app/components/sweet.gjs +3 -0
  10. package/tests/{fixture → fixtures/tests-js-10}/app/router.js +2 -3
  11. package/tests/fixtures/tests-js-10/app/routes/.gitkeep +0 -0
  12. package/tests/{fixture/app/routes/styles.js → fixtures/tests-js-10/app/routes/fancy.js} +1 -1
  13. package/tests/fixtures/tests-js-10/app/styles/app.css +3 -0
  14. package/tests/fixtures/tests-js-10/app/templates/application.gjs +15 -0
  15. package/tests/fixtures/tests-js-10/app/templates/fancy.gjs +12 -0
  16. package/tests/fixtures/tests-js-10/tests/acceptance/index-test.js +26 -0
  17. package/tests/fixtures/tests-js-10/tests/integration/components/sweet-test.gjs +28 -0
  18. package/tests/fixtures/tests-js-10/tests/routes/fancy-test.js +11 -0
  19. package/tests/{fixture-ts/testem-proxy.js → fixtures/tests-js-20/testem-dev.js} +26 -2
  20. package/tests/fixtures/tests-ts-10/app/components/.gitkeep +0 -0
  21. package/tests/fixtures/tests-ts-10/app/components/sweet.gts +3 -0
  22. package/tests/{fixture-ts → fixtures/tests-ts-10}/app/router.ts +2 -3
  23. package/tests/fixtures/tests-ts-10/app/routes/.gitkeep +0 -0
  24. package/tests/{fixture-ts/app/routes/styles.ts → fixtures/tests-ts-10/app/routes/fancy.ts} +1 -1
  25. package/tests/fixtures/tests-ts-10/app/styles/app.css +3 -0
  26. package/tests/fixtures/tests-ts-10/app/templates/application.gts +15 -0
  27. package/tests/fixtures/tests-ts-10/app/templates/fancy.gts +12 -0
  28. package/tests/fixtures/tests-ts-10/tests/acceptance/index-test.ts +26 -0
  29. package/tests/fixtures/tests-ts-10/tests/integration/components/sweet-test.gjs +28 -0
  30. package/tests/fixtures/tests-ts-10/tests/routes/fancy-test.js +11 -0
  31. package/tests/generators.test.mjs +60 -0
  32. package/tests/helpers.mjs +26 -91
  33. package/tests/lint.test.mjs +27 -10
  34. package/tests/tests.test.mjs +218 -0
  35. package/vitest.config.ts +2 -2
  36. package/tests/default.test.mjs +0 -155
  37. package/tests/fixture/app/components/custom-component.hbs +0 -3
  38. package/tests/fixture/app/styles/app.css +0 -5
  39. package/tests/fixture/app/templates/application.hbs +0 -3
  40. package/tests/fixture/app/templates/custom-component.hbs +0 -1
  41. package/tests/fixture/app/templates/index.hbs +0 -1
  42. package/tests/fixture/app/templates/styles.hbs +0 -5
  43. package/tests/fixture/testem-proxy.js +0 -35
  44. package/tests/fixture/tests/acceptance/custom-component-test.js +0 -14
  45. package/tests/fixture/tests/acceptance/styles-test.js +0 -18
  46. package/tests/fixture-ts/app/styles/app.css +0 -5
  47. package/tests/fixture-ts/app/templates/components/custom.gts +0 -5
  48. package/tests/fixture-ts/app/templates/custom-component.gts +0 -5
  49. package/tests/fixture-ts/app/templates/index.gts +0 -5
  50. package/tests/fixture-ts/app/templates/styles.gts +0 -7
  51. package/tests/fixture-ts/tests/acceptance/custom-component-test.ts +0 -14
  52. package/tests/fixture-ts/tests/acceptance/styles-test.ts +0 -18
  53. package/tests/typescript.test.mjs +0 -24
  54. /package/tests/{fixture → fixtures/tests-js-10}/app/initializers/test-init.js +0 -0
  55. /package/tests/{fixture → fixtures/tests-js-10}/app/instance-initializers/test-instance-init.js +0 -0
  56. /package/tests/{fixture → fixtures/tests-js-10}/tests/acceptance/app-init-test.js +0 -0
  57. /package/tests/{fixture → fixtures/tests-js-10}/tests/acceptance/welcome-page-test.js +0 -0
  58. /package/tests/{fixture-ts → fixtures/tests-ts-10}/app/initializers/test-init.ts +0 -0
  59. /package/tests/{fixture-ts → fixtures/tests-ts-10}/app/instance-initializers/test-instance-init.ts +0 -0
  60. /package/tests/{fixture-ts → fixtures/tests-ts-10}/tests/acceptance/app-init-test.ts +0 -0
  61. /package/tests/{fixture-ts → fixtures/tests-ts-10}/tests/acceptance/welcome-page-test.ts +0 -0
@@ -1 +0,0 @@
1
- <CustomComponent />
@@ -1 +0,0 @@
1
- <WelcomePage />
@@ -1,5 +0,0 @@
1
- <h1>Styles test</h1>
2
-
3
- <p class="styles-test">
4
- I expect to be blue
5
- </p>
@@ -1,35 +0,0 @@
1
- const httpProxy = require('http-proxy');
2
-
3
- /*
4
- This can be installed as a testem middleware to make testem run against an
5
- arbitrary real webserver at targetURL.
6
-
7
- It allows testem to handle the well-known testem-specific paths and proxies
8
- everything else, while rewriting the testem-added prefix out of your
9
- "/tests/index.html" URL.
10
- */
11
-
12
- module.exports = function testemProxy(targetURL) {
13
- return function testemProxyHandler(app) {
14
- const proxy = httpProxy.createProxyServer({
15
- changeOrigin: true,
16
- ignorePath: true,
17
- });
18
-
19
- proxy.on('error', (err, _req, res) => {
20
- res && res.status && res.status(500).json(err);
21
- });
22
-
23
- app.all('*', (req, res, next) => {
24
- let url = req.url;
25
- if (url === '/testem.js' || url.startsWith('/testem/')) {
26
- return next();
27
- }
28
- let m = /^(\/\d+)\/tests\/index.html/.exec(url);
29
- if (m) {
30
- url = url.slice(m[1].length);
31
- }
32
- proxy.web(req, res, { target: targetURL + url });
33
- });
34
- };
35
- }
@@ -1,14 +0,0 @@
1
- import { module, test } from 'qunit';
2
- import { visit, currentURL } from '@ember/test-helpers';
3
- import { setupApplicationTest } from 'test-app/tests/helpers';
4
-
5
- module('Acceptance | custom-component page', function (hooks) {
6
- setupApplicationTest(hooks);
7
-
8
- test('visiting /custom-component', async function (assert) {
9
- await visit('/custom-component');
10
-
11
- assert.strictEqual(currentURL(), '/custom-component');
12
- assert.dom('#custom-component').containsText('I am a custom component');
13
- });
14
- })
@@ -1,18 +0,0 @@
1
- import { module, test } from 'qunit';
2
- import { visit } from '@ember/test-helpers';
3
- import { setupApplicationTest } from 'test-app/tests/helpers';
4
-
5
- module('Acceptance | styles', function (hooks) {
6
- setupApplicationTest(hooks);
7
-
8
- test('visiting /styles', async function (assert) {
9
- await visit('/styles');
10
-
11
- assert.dom('.styles-test').hasStyle(
12
- {
13
- 'background-color': 'rgb(0, 0, 255)',
14
- },
15
- 'The background should be blue if the app styles are working correctly',
16
- );
17
- });
18
- });
@@ -1,5 +0,0 @@
1
- /* Ember supports plain CSS out of the box. More info: https://cli.emberjs.com/release/advanced-use/stylesheets/ */
2
-
3
- .styles-test {
4
- background-color: blue;
5
- }
@@ -1,5 +0,0 @@
1
- <template>
2
- <div id="custom-component">
3
- I am a custom component
4
- </div>
5
- </template>
@@ -1,5 +0,0 @@
1
- import Custom from './components/custom';
2
-
3
- <template>
4
- <Custom />
5
- </template>
@@ -1,5 +0,0 @@
1
- import { WelcomePage } from 'ember-welcome-page';
2
-
3
- <template>
4
- <WelcomePage />
5
- </template>
@@ -1,7 +0,0 @@
1
- <template>
2
- <h1>Styles test</h1>
3
-
4
- <p class="styles-test">
5
- I expect to be blue
6
- </p>
7
- </template>
@@ -1,14 +0,0 @@
1
- import { module, test } from 'qunit';
2
- import { visit, currentURL } from '@ember/test-helpers';
3
- import { setupApplicationTest } from 'test-app/tests/helpers';
4
-
5
- module('Acceptance | custom-component page', function (hooks) {
6
- setupApplicationTest(hooks);
7
-
8
- test('visiting /custom-component', async function (assert) {
9
- await visit('/custom-component');
10
-
11
- assert.strictEqual(currentURL(), '/custom-component');
12
- assert.dom('#custom-component').containsText('I am a custom component');
13
- });
14
- })
@@ -1,18 +0,0 @@
1
- import { module, test } from 'qunit';
2
- import { visit } from '@ember/test-helpers';
3
- import { setupApplicationTest } from 'test-app/tests/helpers';
4
-
5
- module('Acceptance | styles', function (hooks) {
6
- setupApplicationTest(hooks);
7
-
8
- test('visiting /styles', async function (assert) {
9
- await visit('/styles');
10
-
11
- assert.dom('.styles-test').hasStyle(
12
- {
13
- 'background-color': 'rgb(0, 0, 255)',
14
- },
15
- 'The background should be blue if the app styles are working correctly',
16
- );
17
- });
18
- });
@@ -1,24 +0,0 @@
1
- import { describe, it, expect } from 'vitest';
2
- import { join } from 'path';
3
- import { existsSync } from 'fs';
4
- import { newProjectWithFixtures } from './helpers.mjs';
5
-
6
- describe('typescript', function () {
7
- let project = newProjectWithFixtures({
8
- fixturePath: join(__dirname, 'fixture-ts'),
9
- flags: ['--typescript'],
10
- });
11
-
12
- it('verify files', async function () {
13
- expect(
14
- existsSync(join(project.dir(), 'tsconfig.json')),
15
- 'the root tsconfig.json has been added',
16
- );
17
- });
18
-
19
- it('glint passes', async function () {
20
- let result = await project.execa('pnpm', ['glint']);
21
-
22
- console.log(result.stdout);
23
- });
24
- });