Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

allure-js-commons

Package Overview
Dependencies
Maintainers
4
Versions
84
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

allure-js-commons - npm Package Compare versions

Comparing version 2.0.0-beta.26 to 2.0.0

dist/src/testplan.d.ts

5

dist/index.d.ts

@@ -11,3 +11,4 @@ export { AllureRuntime } from "./src/AllureRuntime";

export { StepBodyFunction, AllureCommandStep, AllureCommandStepExecutable } from "./src/AllureCommandStep";
export { AttachmentOptions, MetadataMessage, Attachment, Category, ExecutableItem, StepResult, Parameter, StatusDetails, Link, Label, ExecutorInfo, TestResultContainer, FixtureResult, TestResult, ContentType, LabelName, Severity, Stage, Status, LinkType, ParameterOptions, StepMetadata, AttachmentMetadata } from "./src/model";
export { md5, isAnyStepFailed } from "./src/utils";
export { AttachmentOptions, MetadataMessage, Attachment, Category, ExecutableItem, StepResult, Parameter, StatusDetails, Link, Label, ExecutorInfo, TestResultContainer, FixtureResult, TestResult, ContentType, LabelName, Severity, Stage, Status, LinkType, ParameterOptions, StepMetadata, AttachmentMetadata, ImageDiffAttachment } from "./src/model";
export { md5, escapeRegExp, isAnyStepFailed, readImageAsBase64 } from "./src/utils";
export { parseTestPlan } from "./src/testplan";

6

dist/index.js
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.isAnyStepFailed = exports.md5 = exports.LinkType = exports.Status = exports.Stage = exports.Severity = exports.LabelName = exports.ContentType = exports.AllureCommandStepExecutable = exports.Allure = exports.isPromise = exports.AllureStep = exports.AllureTest = exports.ExecutableItemWrapper = exports.AllureGroup = exports.FileSystemAllureWriter = exports.InMemoryAllureWriter = exports.AllureRuntime = void 0;
exports.parseTestPlan = exports.readImageAsBase64 = exports.isAnyStepFailed = exports.escapeRegExp = exports.md5 = exports.LinkType = exports.Status = exports.Stage = exports.Severity = exports.LabelName = exports.ContentType = exports.AllureCommandStepExecutable = exports.Allure = exports.isPromise = exports.AllureStep = exports.AllureTest = exports.ExecutableItemWrapper = exports.AllureGroup = exports.FileSystemAllureWriter = exports.InMemoryAllureWriter = exports.AllureRuntime = void 0;
var AllureRuntime_1 = require("./src/AllureRuntime");

@@ -32,3 +32,7 @@ Object.defineProperty(exports, "AllureRuntime", { enumerable: true, get: function () { return AllureRuntime_1.AllureRuntime; } });

Object.defineProperty(exports, "md5", { enumerable: true, get: function () { return utils_1.md5; } });
Object.defineProperty(exports, "escapeRegExp", { enumerable: true, get: function () { return utils_1.escapeRegExp; } });
Object.defineProperty(exports, "isAnyStepFailed", { enumerable: true, get: function () { return utils_1.isAnyStepFailed; } });
Object.defineProperty(exports, "readImageAsBase64", { enumerable: true, get: function () { return utils_1.readImageAsBase64; } });
var testplan_1 = require("./src/testplan");
Object.defineProperty(exports, "parseTestPlan", { enumerable: true, get: function () { return testplan_1.parseTestPlan; } });
//# sourceMappingURL=index.js.map

@@ -1,1 +0,1 @@

export { ALLURE_METADATA_CONTENT_TYPE } from "./src/model";
export { ALLURE_METADATA_CONTENT_TYPE, ALLURE_IMAGEDIFF_CONTENT_TYPE } from "./src/model";
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.ALLURE_METADATA_CONTENT_TYPE = void 0;
exports.ALLURE_IMAGEDIFF_CONTENT_TYPE = exports.ALLURE_METADATA_CONTENT_TYPE = void 0;
var model_1 = require("./src/model");
Object.defineProperty(exports, "ALLURE_METADATA_CONTENT_TYPE", { enumerable: true, get: function () { return model_1.ALLURE_METADATA_CONTENT_TYPE; } });
Object.defineProperty(exports, "ALLURE_IMAGEDIFF_CONTENT_TYPE", { enumerable: true, get: function () { return model_1.ALLURE_IMAGEDIFF_CONTENT_TYPE; } });
//# sourceMappingURL=internal.js.map

@@ -59,3 +59,3 @@ "use strict";

id(allureId) {
this.label(model_2.LabelName.AS_ID, allureId);
this.label(model_2.LabelName.ALLURE_ID, allureId);
}

@@ -62,0 +62,0 @@ tag(tag) {

@@ -56,4 +56,4 @@ "use strict";

value,
hidden: (options === null || options === void 0 ? void 0 : options.hidden) || false,
excluded: (options === null || options === void 0 ? void 0 : options.excluded) || false,
mode: options === null || options === void 0 ? void 0 : options.mode,
});

@@ -60,0 +60,0 @@ }

/// <reference types="node" />
export declare const ALLURE_METADATA_CONTENT_TYPE = "application/vnd.allure.metadata+json";
export declare const ALLURE_IMAGEDIFF_CONTENT_TYPE = "application/vnd.allure.image.diff";
export interface AttachmentMetadata {

@@ -43,6 +44,6 @@ name: string;

value: string;
hidden?: boolean;
excluded?: boolean;
mode?: "hidden" | "masked" | "default";
}
export declare type ParameterOptions = Pick<Parameter, "hidden" | "excluded">;
export declare type ParameterOptions = Pick<Parameter, "mode" | "excluded">;
export interface StatusDetails {

@@ -115,3 +116,4 @@ message?: string;

export declare enum LabelName {
AS_ID = "AS_ID",
ALLURE_ID = "ALLURE_ID",
AS_ID = "ALLURE_ID",
SUITE = "suite",

@@ -162,1 +164,7 @@ PARENT_SUITE = "parentSuite",

}
export interface ImageDiffAttachment {
expected: string | undefined;
actual: string | undefined;
diff: string | undefined;
name: string;
}
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.LinkType = exports.ContentType = exports.Severity = exports.LabelName = exports.Stage = exports.Status = exports.ALLURE_METADATA_CONTENT_TYPE = void 0;
exports.LinkType = exports.ContentType = exports.Severity = exports.LabelName = exports.Stage = exports.Status = exports.ALLURE_IMAGEDIFF_CONTENT_TYPE = exports.ALLURE_METADATA_CONTENT_TYPE = void 0;
exports.ALLURE_METADATA_CONTENT_TYPE = "application/vnd.allure.metadata+json";
exports.ALLURE_IMAGEDIFF_CONTENT_TYPE = "application/vnd.allure.image.diff";
var Status;

@@ -22,3 +23,4 @@ (function (Status) {

(function (LabelName) {
LabelName["AS_ID"] = "AS_ID";
LabelName["ALLURE_ID"] = "ALLURE_ID";
LabelName["AS_ID"] = "ALLURE_ID";
LabelName["SUITE"] = "suite";

@@ -25,0 +27,0 @@ LabelName["PARENT_SUITE"] = "parentSuite";

import { ExecutableItem, Label } from "./model";
export declare const md5: (data: string) => string;
export declare const getLabelsFromEnv: () => Label[];
export declare const escapeRegExp: (value: string) => string;
export declare const isAnyStepFailed: (item: ExecutableItem) => boolean;
export declare const readImageAsBase64: (path: string) => Promise<string | undefined>;
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.isAnyStepFailed = exports.getLabelsFromEnv = exports.md5 = void 0;
exports.readImageAsBase64 = exports.isAnyStepFailed = exports.escapeRegExp = exports.getLabelsFromEnv = exports.md5 = void 0;
const crypto_1 = require("crypto");
const promises_1 = require("fs/promises");
const process_1 = require("process");

@@ -27,2 +28,7 @@ const model_1 = require("./model");

exports.getLabelsFromEnv = getLabelsFromEnv;
const reRegExpChar = /[\\^$.*+?()[\]{}|]/g, reHasRegExpChar = RegExp(reRegExpChar.source);
const escapeRegExp = (value) => {
return reHasRegExpChar.test(value) ? value.replace(reRegExpChar, "\\$&") : value;
};
exports.escapeRegExp = escapeRegExp;
const isAnyStepFailed = (item) => {

@@ -36,2 +42,12 @@ const isFailed = item.status === model_1.Status.FAILED;

exports.isAnyStepFailed = isAnyStepFailed;
const readImageAsBase64 = async (path) => {
try {
const file = await (0, promises_1.readFile)(path, { encoding: "base64" });
return file ? `data:image/png;base64,${file}` : undefined;
}
catch (e) {
return undefined;
}
};
exports.readImageAsBase64 = readImageAsBase64;
//# sourceMappingURL=utils.js.map
{
"name": "allure-js-commons",
"version": "2.0.0-beta.26",
"version": "2.0.0",
"description": "Allure JS Commons",
"license": "Apache-2.0",
"author": "Ilya Korobitsyn <mail@korobochka.org>",
"author": {
"name": "Qameta Software",
"email": "allure@qameta.io",
"url": "https://qameta.io/"
},
"repository": {

@@ -39,3 +43,3 @@ "type": "git",

"@types/uuid": "^8.3.0",
"allure-mocha": "2.0.0-beta.26",
"allure-mocha": "2.0.0",
"chai": "^4.3.4",

@@ -42,0 +46,0 @@ "glob": "^8.0.0",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc