Added CI test to ensure i18n strings are extracted out

refs https://github.com/TryGhost/Ghost/issues/15502

- this will test if we have strings that aren't present in the JSON
  files in CI, so we don't miss out on translations
This commit is contained in:
Daniel Lockyer 2023-01-19 16:20:55 +01:00
parent 437e1cc936
commit 1f32a7be8a
No known key found for this signature in database
2 changed files with 4 additions and 1 deletions

View File

@ -10,5 +10,7 @@ module.exports = {
indentation: 4,
sort: true,
failOnUpdate: process.env.CI,
output: 'locales/$LOCALE.json'
};

View File

@ -8,7 +8,8 @@
"scripts": {
"dev": "echo \"Implement me!\"",
"test:unit": "NODE_ENV=testing c8 --include index.js --include lib --check-coverage --100 --reporter text --reporter cobertura mocha './test/**/*.test.js'",
"test": "yarn test:unit",
"test": "yarn test:unit && yarn test:translate",
"test:translate": "yarn translate:portal",
"lint:code": "eslint *.js lib/ --ext .js --cache",
"lint": "yarn lint:code && yarn lint:test",
"lint:test": "eslint -c test/.eslintrc.js test/ --ext .js --cache",