Skip to content

Commit f4d1eca

Browse files
authored
Merge pull request #295 from currents-dev/feat/reuse-full-test-suite
[CSR-3277] feat: reuse full test suite file if exists
2 parents 94d2d7e + 0b1f494 commit f4d1eca

2 files changed

Lines changed: 7 additions & 9 deletions

File tree

packages/cmd/src/services/upload/index.ts

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,9 @@ import {
2020
getInstanceReportList,
2121
resolveReportOptions,
2222
} from './fs';
23+
import { getFullTestSuiteFilePath } from './path';
2324
import { ReportConfig, UploadMarkerInfo } from './types';
2425
import { splitArrayIntoChunks } from './utils';
25-
import { getFullTestSuiteFilePath } from './path';
2626

2727
export async function handleCurrentsReport() {
2828
const currentsConfig = getCurrentsConfig();
@@ -64,15 +64,12 @@ export async function handleCurrentsReport() {
6464
runUrl: markerInfo.response.runUrl,
6565
isoDate: markerInfo.isoDate,
6666
});
67+
}
6768

68-
const fullTestSuiteFileExists = await checkPathExists(
69-
fullTestSuiteFilePath
70-
);
71-
72-
if (fullTestSuiteFileExists) {
73-
fullTestSuite = await readJsonFile<FullTestSuite>(fullTestSuiteFilePath);
74-
debug('Full test suite file detected: %s', fullTestSuiteFilePath);
75-
}
69+
const fullTestSuiteFileExists = await checkPathExists(fullTestSuiteFilePath);
70+
if (fullTestSuiteFileExists) {
71+
fullTestSuite = await readJsonFile<FullTestSuite>(fullTestSuiteFilePath);
72+
debug('Full test suite file detected: %s', fullTestSuiteFilePath);
7673
}
7774

7875
if (!fullTestSuite) {

packages/cmd/src/types.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ export type InstanceReportTest = {
6464
expectedStatus?: ExpectedStatus;
6565
annotations?: unknown[];
6666
timeout: number;
67+
tags?: string[];
6768
location: LocationSchema;
6869
attempts: InstanceReportTestAttempt[];
6970
};

0 commit comments

Comments
 (0)