jest-allure2-adapter
Advanced tools
Comparing version 0.3.5 to 0.3.6
/// <reference types="node" /> | ||
import { AllureCurrentApi } from './index'; | ||
import { AllureRuntime, ContentType, ExecutableItemWrapper } from 'allure-js-commons'; | ||
import { AttachmentOptions } from 'allure-js-commons/dist/src/model'; | ||
export declare class AllureCurrent implements AllureCurrentApi { | ||
@@ -10,3 +11,3 @@ private runtime; | ||
private action; | ||
attachment(name: string, content: Buffer | string, type?: ContentType): void; | ||
attachment(name: string, content: Buffer | string, type?: ContentType | string | AttachmentOptions): void; | ||
addParameter(name: string, value: string): this; | ||
@@ -13,0 +14,0 @@ addParameters(...params: [string, any][]): this; |
/// <reference types="node" /> | ||
import { Allure, AllureStep, AllureTest, Attachment, Category, ContentType, ExecutableItemWrapper, LinkType, Severity, Stage, Status, StatusDetails, StepInterface } from 'allure-js-commons'; | ||
import { AllureAdapterConfig, AllureCurrentApi, AllureReporterApi, jasmine_ } from './index'; | ||
import { AttachmentOptions } from 'allure-js-commons/dist/src/model'; | ||
export declare class AllureReporter extends Allure implements AllureReporterApi { | ||
@@ -27,3 +28,4 @@ private config?; | ||
endStep(status?: Status, stage?: Stage, details?: StatusDetails | any, end?: number): void; | ||
setHistoryId(fullName: string): void; | ||
setHistoryId(uid: string): void; | ||
setFullName(fullName: string): void; | ||
endTest(spec: jasmine_.CustomReporterResult): void; | ||
@@ -35,3 +37,3 @@ endGroup(): void; | ||
logStep(name: string, status: Status, attachments?: [Attachment]): void; | ||
attachment(name: string, content: Buffer | string, type?: ContentType): void; | ||
attachment(name: string, content: Buffer | string, type?: ContentType | string | AttachmentOptions): void; | ||
addParameter(name: string, value: string): this; | ||
@@ -38,0 +40,0 @@ addParameters(...params: [string, any][]): this; |
@@ -114,8 +114,11 @@ "use strict"; | ||
} | ||
setHistoryId(fullName) { | ||
setHistoryId(uid) { | ||
const getUuid = require('uuid-by-string'); | ||
const id = getUuid(fullName); | ||
this.currentTest.historyId = id; | ||
this.currentTest.historyId = getUuid(uid); | ||
} | ||
setFullName(fullName) { | ||
this.currentTest.fullName = fullName; | ||
} | ||
endTest(spec) { | ||
var _a; | ||
this.endSteps(); | ||
@@ -159,3 +162,5 @@ if (spec.status === SpecStatus.PASSED) { | ||
this.applyDescription(); | ||
this.setHistoryId(spec.fullName); | ||
if (((_a = this.config) === null || _a === void 0 ? void 0 : _a.historyIdByName) !== false) { | ||
this.setHistoryId(spec.fullName); | ||
} | ||
this.currentTest.endTest(); | ||
@@ -162,0 +167,0 @@ } |
@@ -51,2 +51,4 @@ /// <reference types="node" /> | ||
addDescription(description: string): void; | ||
setFullName(fullName: string): void; | ||
setHistoryId(uid: string): void; | ||
addPackage(value: string): this; | ||
@@ -86,2 +88,3 @@ addLink(options: { | ||
addStepStatusDetailsAttachment?: boolean; | ||
historyIdByName?: boolean; | ||
tmsLink?: (id: string) => string; | ||
@@ -88,0 +91,0 @@ issueLink?: (id: string) => string; |
/// <reference types="node" /> | ||
import { ContentType } from 'allure-js-commons'; | ||
import { AttachmentOptions } from 'allure-js-commons/dist/src/model'; | ||
export declare const dateStr: (isFileName?: boolean) => string; | ||
export declare function getContent(content: Buffer | string, type: ContentType): any; | ||
export declare function getContent(content: Buffer | string, type: ContentType | string | AttachmentOptions): any; |
{ | ||
"name": "jest-allure2-adapter", | ||
"version": "0.3.5", | ||
"version": "0.3.6", | ||
"description": "Allure 2 Adapter for jest", | ||
@@ -45,3 +45,3 @@ "main": "./dist/index", | ||
"@types/strip-ansi": "^5.2.0", | ||
"allure-js-commons": "^2.0.0-beta.8", | ||
"allure-js-commons": "^2.0.0-beta.9", | ||
"strip-ansi": "^6.0.0", | ||
@@ -48,0 +48,0 @@ "uuid-by-string": "^3.0.2" |
@@ -292,2 +292,7 @@ # Jest-Allure-2 reporting plugin | ||
#### 0.3.6: | ||
- ability to setup historyId and fullName | ||
- added historyIdByName into config (when false need to setup historyId manually to have correct retries, by default it is true and historyId is being generated by spec full name) | ||
#### 0.3.5: | ||
@@ -294,0 +299,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
2950145
54
51989
359