Chore upgrade ember intl (#1425)
* refactor: 💡 explicitly inject the store service - icu-6770 ✅ Closes: icu-6770 * refactor: 💡 upgrade to ember-intl 6.0.1 includes locale initialization and smoke tests * refactor: 💡 migrate admin and desktop to ember-intl 6.x ✅ Closes: icu-6771 * chore: 🤖 exclude cldr-core@38.1.0 from license checking this license was manually checked * fix: 🐛 fix text naming and linting * chore: 🤖 update to ember-intl beta
This commit is contained in:
1 parent
c107fa872c
commit
0c819d6d12
17 files changed
+203
-92
No files matched your search
@@ -39,7 +39,7 @@
|
||||
"ember-cli-babel": "^7.26.8",
|
||||
"ember-cli-htmlbars": "^6.1.0",
|
||||
"ember-feature-flags": "^6.0.0",
|
||||
"ember-intl": "^5.7.0",
|
||||
"ember-intl": "^6.0.0-beta.4",
|
||||
"ember-loading": "^2.0.0",
|
||||
"ember-route-action-helper": "^2.0.8",
|
||||
"ember-truth-helpers": "^3.0.0"
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
import { module, test } from 'qunit';
|
||||
import { visit, currentURL } from '@ember/test-helpers';
|
||||
import { setupApplicationTest } from 'ember-qunit';
|
||||
|
||||
module('Acceptance | index test', function (hooks) {
|
||||
setupApplicationTest(hooks);
|
||||
|
||||
test('visiting /', async function (assert) {
|
||||
await visit('/');
|
||||
assert.deepEqual(currentURL(), '/');
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,13 @@
|
||||
import { module, test } from 'qunit';
|
||||
import { visit, currentURL } from '@ember/test-helpers';
|
||||
import { setupApplicationTest } from 'ember-qunit';
|
||||
|
||||
module('Acceptance | smoke test', function (hooks) {
|
||||
setupApplicationTest(hooks);
|
||||
|
||||
test('visiting /smoke', async function (assert) {
|
||||
await visit('/smoke');
|
||||
|
||||
assert.deepEqual(currentURL(), '/smoke');
|
||||
});
|
||||
});
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
import Controller from '@ember/controller';
|
||||
import { inject as service } from '@ember/service';
|
||||
|
||||
export default class ApplicationController extends Controller {
|
||||
export default class IndexController extends Controller {
|
||||
// =services
|
||||
|
||||
@service clockTick;
|
||||
@@ -6,4 +6,6 @@ export default class Router extends EmberRouter {
|
||||
rootURL = config.rootURL;
|
||||
}
|
||||
|
||||
Router.map(function () {});
|
||||
Router.map(function () {
|
||||
this.route('smoke');
|
||||
});
|
||||
@@ -0,0 +1,10 @@
|
||||
import Route from '@ember/routing/route';
|
||||
import { inject as service } from '@ember/service';
|
||||
|
||||
export default class ApplicationRoute extends Route {
|
||||
@service intl;
|
||||
|
||||
beforeModel() {
|
||||
this.intl.setLocale(['en-us']);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
import Route from '@ember/routing/route';
|
||||
|
||||
export default class SmokeRoute extends Route {}
|
||||
@@ -1,2 +1 @@
|
||||
<h2 id='title'>Welcome to Ember</h2>
|
||||
<p>{{relative-datetime-live this.now}}</p>
|
||||
{{outlet}}
|
||||
@@ -0,0 +1,2 @@
|
||||
<h2 id='title'>Welcome to Ember</h2>
|
||||
<p>{{relative-datetime-live this.now}}</p>
|
||||
@@ -0,0 +1,8 @@
|
||||
<h1>Smoke Test</h1>
|
||||
<p>
|
||||
This template is used by the smoke-test acceptance tests, which validate that
|
||||
Ember can start up and basic features work as intended.
|
||||
</p>
|
||||
|
||||
<h2>{{t 'resources.account.title'}}</h2>
|
||||
<p>{{t 'resources.account.description'}}</p>
|
||||
@@ -2,9 +2,11 @@ import { module, test } from 'qunit';
|
||||
import { setupRenderingTest } from 'ember-qunit';
|
||||
import { render, find } from '@ember/test-helpers';
|
||||
import { hbs } from 'ember-cli-htmlbars';
|
||||
import { setupIntl } from 'ember-intl/test-support';
|
||||
|
||||
module('Integration | Component | error/message', function (hooks) {
|
||||
setupRenderingTest(hooks);
|
||||
setupIntl(hooks);
|
||||
|
||||
test('it renders predefined message for known error status', async function (assert) {
|
||||
await render(hbs`<Error::Message @status='401' />`);
|
||||
|
||||
Reference in new issue
Block a user