Skip to content

Commit

Permalink
Fix all test in strapi v4 (#183)
Browse files Browse the repository at this point in the history
  • Loading branch information
wil92 committed May 1, 2023
1 parent 1f88404 commit 7913d25
Show file tree
Hide file tree
Showing 121 changed files with 25,045 additions and 5,014 deletions.
11 changes: 10 additions & 1 deletion config/admin.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,15 @@
module.exports = ({env}) => ({
autoOpen: false,
prefix: '',
auth: {
secret: env('ADMIN_JWT_SECRET', '6V#j7xt3ZHBgBphIiwv2')
}
},
apiToken: {
salt: env('API_TOKEN_SALT', 'asdf234rqsdr32wetw3tr3'),
},
transfer: {
token: {
salt: env('TRANSFER_TOKEN_SALT', 'asdfasdf2342twdr'),
},
},
});
10 changes: 10 additions & 0 deletions config/api.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
module.exports = ({ env }) => ({
responses: {
// privateAttributes: ['_v', 'id', 'created_at'],
},
rest: {
// prefix: '',
// defaultLimit: 100,
// maxLimit: 250,
},
});
2 changes: 1 addition & 1 deletion config/database.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ module.exports = ({env}) => ({
connection: {
host: env('DATABASE_HOST', 'mysql'),
port: env.int('DATABASE_PORT', 3306),
database: env('DATABASE_NAME', 'blog'),
database: env('DATABASE_NAME', 'news'),
user: env('DATABASE_USERNAME', 'api'),
password: env('DATABASE_PASSWORD', 'password')
},
Expand Down
2 changes: 1 addition & 1 deletion config/env/test/database.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ module.exports = ({env}) => ({
connection: {
filename: path.join(__dirname, '..', '..', '..', env('DATABASE_FILENAME', '.tmp/data.db')),
},
debug: true,
debug: false,
useNullAsDefault: true,
}
});
7 changes: 0 additions & 7 deletions config/functions/bootstrap.js

This file was deleted.

17 changes: 0 additions & 17 deletions config/functions/cron.js

This file was deleted.

5 changes: 0 additions & 5 deletions config/functions/responses/404.js

This file was deleted.

3 changes: 0 additions & 3 deletions config/locales/de_de.json

This file was deleted.

3 changes: 0 additions & 3 deletions config/locales/en_us.json

This file was deleted.

3 changes: 0 additions & 3 deletions config/locales/es_es.json

This file was deleted.

3 changes: 0 additions & 3 deletions config/locales/fr_fr.json

This file was deleted.

3 changes: 0 additions & 3 deletions config/locales/it_it.json

This file was deleted.

3 changes: 0 additions & 3 deletions config/locales/ja_jp.json

This file was deleted.

4 changes: 0 additions & 4 deletions config/locales/ru_ru.json

This file was deleted.

3 changes: 0 additions & 3 deletions config/locales/tr_tr.json

This file was deleted.

2 changes: 1 addition & 1 deletion config/middlewares.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module.exports = [
'strapi::security',
'strapi::cors',
{name: 'strapi::poweredBy', config: {poweredBy: 'Binary Coffee <strapi.io>'}},
// 'strapi::logger',
'strapi::logger',
'strapi::query',
'strapi::body',
{name: 'strapi::session', config: {signed: false}},
Expand Down
11 changes: 7 additions & 4 deletions config/server.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,14 @@ const cronTasks = require("./cron-tasks");
module.exports = ({env}) => ({
host: env('HOST', '0.0.0.0'),
port: env.int('PORT', 1337),
cron: {
enabled: true,
tasks: cronTasks
},
// cron: {
// enabled: true,
// tasks: cronTasks
// },
app: {
keys: [env('SECRET1', 'mySecretKey1'), env('SECRET2', 'mySecretKey2')]
},
webhooks: {
populateRelations: env.bool('WEBHOOKS_POPULATE_RELATIONS', false),
}
});
Loading

0 comments on commit 7913d25

Please sign in to comment.