Skip to content

Commit

Permalink
test(ivy): i18n - add compile time translation to integration test
Browse files Browse the repository at this point in the history
  • Loading branch information
petebacondarwin committed Sep 30, 2019
1 parent 3d604fe commit 13aa1f1
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 2 deletions.
1 change: 1 addition & 0 deletions integration/.gitignore
@@ -1,6 +1,7 @@
built/
dist/
vendor/
translations/
*/src/*.d.ts
*/src/*.js
!karma.conf.js
Expand Down
2 changes: 1 addition & 1 deletion integration/cli-hello-world-ivy-i18n/angular.json
Expand Up @@ -40,7 +40,7 @@
],
"optimization": true,
"outputHashing": "all",
"sourceMap": false,
"sourceMap": true,
"extractCss": true,
"namedChunks": false,
"aot": true,
Expand Down
7 changes: 7 additions & 0 deletions integration/cli-hello-world-ivy-i18n/locales/messages.de.json
@@ -0,0 +1,7 @@
{
"locale": "de",
"translations": {
"1638894134994447485": " Guten Tag, {$INTERPOLATION}! (inline)",
"6762263703087737643": "Willkommen in der i18n App. (inline)"
}
}
7 changes: 7 additions & 0 deletions integration/cli-hello-world-ivy-i18n/locales/messages.fr.json
@@ -0,0 +1,7 @@
{
"locale": "fr",
"translations": {
"1638894134994447485": " Bonjour, {$INTERPOLATION}! (inline)",
"6762263703087737643": "Bienvenue sur l'application i18n. (inline)"
}
}
4 changes: 3 additions & 1 deletion integration/cli-hello-world-ivy-i18n/package.json
Expand Up @@ -10,7 +10,9 @@
"postinstall": "webdriver-manager update --gecko=false --standalone=false $CI_CHROMEDRIVER_VERSION_ARG",
"start": "ng serve",
"pretest": "ng version",
"test": "ng test --progress=false --watch=false && yarn e2e --configuration=ci && yarn e2e --configuration=ci-production"
"test": "ng test --progress=false --watch=false && yarn e2e --configuration=ci && yarn e2e --configuration=ci-production",
"pretranslate": "yarn build",
"translate": "localize-translate -r \"dist/\" -s \"**/*\" -t \"locales/**\" -o \"translations/{{LOCALE}}\""
},
"private": true,
"dependencies": {
Expand Down

0 comments on commit 13aa1f1

Please sign in to comment.