chore(misc): remove daemon logs (#20248)
This commit is contained in:
parent
2c88282e8a
commit
acb37936fe
@ -7,15 +7,10 @@ import {
|
|||||||
getStrippedEnvironmentVariables,
|
getStrippedEnvironmentVariables,
|
||||||
updateJson,
|
updateJson,
|
||||||
isVerboseE2ERun,
|
isVerboseE2ERun,
|
||||||
readFile,
|
|
||||||
} from '@nx/e2e/utils';
|
} from '@nx/e2e/utils';
|
||||||
import { spawn } from 'child_process';
|
import { spawn } from 'child_process';
|
||||||
import { join } from 'path';
|
import { join } from 'path';
|
||||||
import { writeFileSync, mkdtempSync } from 'fs';
|
import { writeFileSync } from 'fs';
|
||||||
import { tmpdir } from 'os';
|
|
||||||
|
|
||||||
let cacheDirectory = mkdtempSync(join(tmpdir(), 'daemon'));
|
|
||||||
console.log('cache directory', cacheDirectory);
|
|
||||||
|
|
||||||
async function writeFileForWatcher(path: string, content: string) {
|
async function writeFileForWatcher(path: string, content: string) {
|
||||||
const e2ePath = join(tmpProjPath(), path);
|
const e2ePath = join(tmpProjPath(), path);
|
||||||
@ -38,15 +33,11 @@ describe('Nx Watch', () => {
|
|||||||
env: {
|
env: {
|
||||||
NX_DAEMON: 'true',
|
NX_DAEMON: 'true',
|
||||||
NX_NATIVE_LOGGING: 'nx',
|
NX_NATIVE_LOGGING: 'nx',
|
||||||
NX_PROJECT_GRAPH_CACHE_DIRECTORY: cacheDirectory,
|
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
afterEach(() => {
|
afterEach(() => {
|
||||||
let daemonLog = readFile(join(cacheDirectory, 'd/daemon.log'));
|
|
||||||
const testName = expect.getState().currentTestName;
|
|
||||||
console.log(`${testName} daemon log: \n${daemonLog}`);
|
|
||||||
runCLI('reset');
|
runCLI('reset');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user