diff --git a/templates/mellow-svelte/config/env/testing.js b/templates/mellow-svelte/config/env/testing.js new file mode 100644 index 00000000..5b6a0f82 --- /dev/null +++ b/templates/mellow-svelte/config/env/testing.js @@ -0,0 +1,27 @@ +module.exports = { + port: 3333, + hooks: { + // Uncomment if you have the apianalytics hook and you don't want to see logs + // from it during testing + // apianalytics: false + }, + log: { + level: 'error' + }, + models: { + migrate: 'drop' + }, + datastores: { + default: { + adapter: 'sails-disk' + } + }, + mail: { + default: 'log', + mailers: { + log: { + transport: 'log' + } + } + } +} diff --git a/templates/mellow-svelte/tests/unit/helpers.test.js b/templates/mellow-svelte/tests/unit/helpers.test.js index aa6d7a99..b0195052 100644 --- a/templates/mellow-svelte/tests/unit/helpers.test.js +++ b/templates/mellow-svelte/tests/unit/helpers.test.js @@ -9,7 +9,7 @@ describe('sails.helpers.capitalize()', () => { before(async () => { sails = await new Promise((resolve, reject) => { sailsApp.load( - { environment: 'test', hooks: { shipwright: false } }, + { environment: 'testing', hooks: { shipwright: false } }, (err, sailsInstance) => { if (err) { return reject(err) @@ -49,7 +49,7 @@ describe('sails.helpers.getUserIntials()', () => { before(async () => { sails = await new Promise((resolve, reject) => { sailsApp.load( - { environment: 'test', hooks: { shipwright: false } }, + { environment: 'testing', hooks: { shipwright: false } }, (err, sailsInstance) => { if (err) { return reject(err)