@gurglosa/playwright-zephyr-jira-reporter
Version:
A custom Playwright reporter that syncs test results to Zephyr Scale and creates Jira bugs on failures.
61 lines (60 loc) • 1.64 kB
TypeScript
export declare enum TestExecutionStatus {
passed = "Pass",
failed = "Fail",
skipped = "Blocked",
timedOut = "Fail",
interrupted = "Fail",
in_progress = "In Progress",
UNKNOWN = "Blocked"
}
interface CustomFields {
"Build Number"?: number;
"Release Date"?: string;
"Pre-Condition(s)"?: string;
"Implemented"?: boolean;
"Category"?: string[];
"Tester"?: string;
}
export interface UpdateTestExecutionParams {
projectKey: string;
testCaseKey: string;
testCycleKey: string;
statusName: TestExecutionStatus;
testScriptResults?: any;
environmentName: string;
actualEndDate?: string;
executedBy?: string;
executionTime: number;
assignedToId?: string;
comment?: string;
customFields?: CustomFields;
}
export interface TestExecutionResponse {
id: number;
key: string;
projectKey: string;
testCaseKey: string;
testCycleKey: string;
statusName: string;
comment: string;
executedBy: string;
executionDate: string;
createdOn: string;
updatedOn: string;
}
export interface TestCaseIssueLink {
issueId: string;
}
export declare class ZephyrServices {
private client;
constructor(config: {
Zephyr_Base_URL: string;
Zephyr_Access_Token: string;
Zephyr_Test_Cycle_ID: string;
Zephyr_Enabled: boolean;
Zephyr_Test_Project_Key: string;
});
updateTestExecutionStatus(params: UpdateTestExecutionParams): Promise<TestExecutionResponse>;
linkIssueToTestCase(testCaseKey: string, link: TestCaseIssueLink): Promise<void>;
}
export default ZephyrServices;