Updates
This commit is contained in:
+4
-2
@@ -160,9 +160,12 @@ test('queryLogs audit from temp file', async (t) => {
|
||||
t.ok(res.entries[0].message.includes('runJob'))
|
||||
})
|
||||
|
||||
test('queryLogs journal disabled / unsupported', async (t) => {
|
||||
test('queryLogs journal default on / disable / unsupported', async (t) => {
|
||||
const prev = process.env.PEARDATA_JOURNAL
|
||||
delete process.env.PEARDATA_JOURNAL
|
||||
t.ok(isJournalEnabled(), 'journal enabled by default')
|
||||
|
||||
process.env.PEARDATA_JOURNAL = '0'
|
||||
t.absent(isJournalEnabled())
|
||||
const off = await queryLogs({ source: 'journal', role: Roles.admin })
|
||||
t.absent(off.ok)
|
||||
@@ -175,7 +178,6 @@ test('queryLogs journal disabled / unsupported', async (t) => {
|
||||
t.absent(uns.ok)
|
||||
t.is(uns.error, 'unsupported')
|
||||
} else {
|
||||
// On Linux with journal enabled, inject a fake spawn that fails cleanly
|
||||
const res = await queryLogs(
|
||||
{ source: 'journal', role: Roles.admin, limit: 5 },
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user