Release v2.17.5
This commit is contained in:
1 parent
46636939de
commit
86b9609ea7
11 files changed
+285
-56
No files matched your search
@@ -161,8 +161,9 @@ test('2.17.0 migration adds the expiring view-as session columns', async () => {
|
||||
]);
|
||||
|
||||
const pending = await getPendingMigrations(pool, { currentVersion: '2.16.2' });
|
||||
assert.deepEqual(pending.map(function (migration) { return migration.version; }), ['2.17.0', '2.17.1']);
|
||||
await pending[0].run(pool);
|
||||
const viewAsMigration = pending.find(function (migration) { return migration.version === '2.17.0'; });
|
||||
assert.ok(viewAsMigration);
|
||||
await viewAsMigration.run(pool);
|
||||
|
||||
assert.ok(pool.queries.some(function ([sql]) {
|
||||
return String(sql).includes('ALTER TABLE a_sessions ADD COLUMN view_as_user_id INT NULL AFTER user_id');
|
||||
@@ -189,8 +190,9 @@ test('2.17.1 migration removes obsolete dashboard.allow grants and permission',
|
||||
]);
|
||||
|
||||
const pending = await getPendingMigrations(pool, { currentVersion: '2.17.0' });
|
||||
assert.deepEqual(pending.map(function (migration) { return migration.version; }), ['2.17.1']);
|
||||
await pending[0].run(pool);
|
||||
const obsoletePermissionMigration = pending.find(function (migration) { return migration.version === '2.17.1'; });
|
||||
assert.ok(obsoletePermissionMigration);
|
||||
await obsoletePermissionMigration.run(pool);
|
||||
|
||||
assert.ok(pool.queries.some(function ([sql, params]) {
|
||||
return String(sql).includes('DELETE role_permissions') && params[0] === 'dashboard.allow';
|
||||
|
||||
Reference in new issue
Block a user