Skip to content

Commit

Permalink
update getMetadata.spec
Browse files Browse the repository at this point in the history
  • Loading branch information
vpiyachinda committed Feb 7, 2024
1 parent 3091819 commit d146b9c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/test/common/getMetadata.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,14 +44,14 @@ describe('getMetadata', () => {
testRunner: 'jest',
testRunnerVersion: '28.5.0',
cpuCount: 0,
id: '1658821493_1'
id: uuidv4() // '1658821493_1'
};

test('should return the correct metadata with mocked dependencies', () => {
const username = 'username';
const sha = 'ffac537e6cbbf934b08745a378932722df287a53';
const branch = 'master';
const runid = '1658821493';
// const runid = '1658821493';
mockedChildProcess.spawnSync.mockReturnValueOnce({
stdout: Buffer.from(branch),
} as mockSpawnSyncReturns);
Expand Down Expand Up @@ -79,7 +79,7 @@ describe('getMetadata', () => {
GITHUB_TRIGGERING_ACTOR: username,
GITHUB_SHA: sha,
GITHUB_REF_NAME: branch,
GITHUB_RUN_ID: runid
GITHUB_RUN_ID: undefined // runid
};
const actualMetadata:IMetadata = getMetadata('jest');
expect(actualMetadata).toEqual(expectedMetadata);
Expand Down

0 comments on commit d146b9c

Please sign in to comment.