mirror of
https://github.com/0rangebananaspy/authelia.git
synced 2024-09-14 22:47:21 +07:00
Move users_database.yml files to dedicated suites.
This commit is contained in:
parent
4c0bb2ce7f
commit
e8d7fe4111
|
@ -8,13 +8,11 @@ images/
|
|||
example/
|
||||
|
||||
.travis.yml
|
||||
config.test.yml
|
||||
CONTRIBUTORS.md
|
||||
Dockerfile
|
||||
docker-compose.*
|
||||
Gruntfile.js
|
||||
tslint.json
|
||||
tsconfig.json
|
||||
users_database.yml
|
||||
|
||||
*.tgz
|
||||
|
|
1
test/suites/.gitignore
vendored
Normal file
1
test/suites/.gitignore
vendored
Normal file
|
@ -0,0 +1 @@
|
|||
users_database.test.yml
|
|
@ -10,7 +10,7 @@ default_redirection_url: https://home.example.com:8080/
|
|||
|
||||
authentication_backend:
|
||||
file:
|
||||
path: ./users_database.yml
|
||||
path: ./test/suites/basic/users_database.test.yml
|
||||
|
||||
session:
|
||||
secret: unsecure_session_secret
|
||||
|
|
|
@ -12,6 +12,7 @@ const dockerEnv = new DockerEnvironment([
|
|||
])
|
||||
|
||||
async function setup() {
|
||||
await exec(`cp ${__dirname}/users_database.yml ${__dirname}/users_database.test.yml`);
|
||||
await exec('mkdir -p /tmp/authelia/db');
|
||||
await exec('./example/compose/nginx/portal/render.js ' + (fs.existsSync('.suite') ? '': '--production'));
|
||||
await dockerEnv.start();
|
||||
|
|
|
@ -12,8 +12,9 @@ import { exec } from '../../helpers/utils/exec';
|
|||
|
||||
AutheliaSuite('Simple configuration', __dirname, function() {
|
||||
this.timeout(10000);
|
||||
|
||||
beforeEach(async function() {
|
||||
await exec('cp users_database.example.yml users_database.yml');
|
||||
await exec(`cp ${__dirname}/users_database.yml ${__dirname}/users_database.test.yml`);
|
||||
});
|
||||
|
||||
describe('Simple authentication', SimpleAuthentication);
|
||||
|
|
|
@ -10,7 +10,7 @@ default_redirection_url: https://home.example.com:8080/
|
|||
|
||||
authentication_backend:
|
||||
file:
|
||||
path: ./users_database.yml
|
||||
path: ./test/suites/short-timeouts/users_database.test.yml
|
||||
|
||||
session:
|
||||
secret: unsecure_session_secret
|
||||
|
|
|
@ -12,6 +12,7 @@ const dockerEnv = new DockerEnvironment([
|
|||
])
|
||||
|
||||
async function setup() {
|
||||
await exec(`cp ${__dirname}/users_database.yml ${__dirname}/users_database.test.yml`);
|
||||
await exec('mkdir -p /tmp/authelia/db');
|
||||
await exec('./example/compose/nginx/portal/render.js ' + (fs.existsSync('.suite') ? '': '--production'));
|
||||
await dockerEnv.start();
|
||||
|
|
|
@ -1,12 +1,7 @@
|
|||
import AutheliaSuite from "../../helpers/context/AutheliaSuite";
|
||||
import Inactivity from './scenarii/Inactivity';
|
||||
import { exec } from '../../helpers/utils/exec';
|
||||
|
||||
AutheliaSuite('Short timeouts', __dirname, function() {
|
||||
this.timeout(10000);
|
||||
beforeEach(async function() {
|
||||
await exec('cp users_database.example.yml users_database.yml');
|
||||
});
|
||||
|
||||
describe('Inactivity period', Inactivity);
|
||||
});
|
Loading…
Reference in New Issue
Block a user