Skip to content

Commit

Permalink
[jest] Updates snapshot to be less effected by env
Browse files Browse the repository at this point in the history
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
  • Loading branch information
Tyler Smalley committed Nov 9, 2021
1 parent 21ba17d commit b632912
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions packages/kbn-cli-dev-mode/src/dev_server.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ beforeEach(() => {
jest.clearAllMocks();
log.messages.length = 0;
process.execArgv = ['--inheritted', '--exec', '--argv'];
process.env.FORCE_COLOR = process.env.FORCE_COLOR || 'true';
currentProc = undefined;
});

Expand Down Expand Up @@ -121,9 +122,6 @@ describe('#run$', () => {
it('starts the dev server with the right options', () => {
run(new DevServer(defaultOptions)).unsubscribe();

// ensure that FORCE_COLOR is in the env for consistency in snapshot
process.env.FORCE_COLOR = process.env.FORCE_COLOR || 'true';

expect(execa.node.mock.calls).toMatchInlineSnapshot(`
Array [
Array [
Expand Down

0 comments on commit b632912

Please sign in to comment.