Create /tmp/authelia/db directory when starting minimal suite.

This commit is contained in:
Clement Michaud 2019-03-01 21:40:44 +01:00
parent d2ae2524b7
commit a56e5adc42
2 changed files with 9 additions and 2 deletions

View File

@ -21,7 +21,7 @@ session:
# Configuration of the storage backend used to store data and secrets. i.e. totp data
storage:
local:
path: /var/lib/authelia/db
path: /tmp/authelia/db
# TOTP Issuer Name
#

View File

@ -15,10 +15,17 @@ import SimpleAuthentication from './scenarii/SimpleAuthentication';
const execAsync = Bluebird.promisify(ChildProcess.exec);
before(async function() {
await execAsync('mkdir -p /tmp/authelia/db');
});
after(async function() {
await execAsync('rm -r /tmp/authelia/db');
});
AutheliaSuite('Minimal configuration', __dirname + '/config.yml', function() {
this.timeout(10000);
beforeEach(async function() {
await execAsync('mkdir -p /var/lib/authelia/db')
await execAsync('cp users_database.example.yml users_database.yml');
});