New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@estruyf/github-actions-reporter

Package Overview
Dependencies
Maintainers
1
Versions
41
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@estruyf/github-actions-reporter - npm Package Compare versions

Comparing version

to
1.10.0-beta.1292628

4

dist/index.js

@@ -40,2 +40,3 @@ "use strict";

showAnnotations: true,
showAnnotationsInColumn: false,
showTags: true,

@@ -50,2 +51,5 @@ quiet: false,

}
if (typeof options.showAnnotationsInColumn === "undefined") {
this.options.showAnnotationsInColumn = false;
}
if (typeof options.showTags === "undefined") {

@@ -52,0 +56,0 @@ this.options.showTags = true;

@@ -6,2 +6,3 @@ import { DisplayLevel } from ".";

showAnnotations: boolean;
showAnnotationsInColumn?: boolean;
showTags: boolean;

@@ -8,0 +9,0 @@ showError?: boolean;

2

dist/utils/getHtmlTable.d.ts
import { TestCase } from "@playwright/test/reporter";
import { BlobService, DisplayLevel } from "../models";
export declare const getHtmlTable: (tests: TestCase[], showAnnotations: boolean, showTags: boolean, showError: boolean, displayLevel: DisplayLevel[], blobService?: BlobService) => Promise<string | undefined>;
export declare const getHtmlTable: (tests: TestCase[], showAnnotations: boolean, showTags: boolean, showError: boolean, displayLevel: DisplayLevel[], showAnnotationsInColumn?: boolean, blobService?: BlobService) => Promise<string | undefined>;

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

const processAttachments_1 = require("./processAttachments");
const getHtmlTable = (tests, showAnnotations, showTags, showError, displayLevel, blobService) => __awaiter(void 0, void 0, void 0, function* () {
const getHtmlTable = (tests, showAnnotations, showTags, showError, displayLevel, showAnnotationsInColumn = false, blobService) => __awaiter(void 0, void 0, void 0, function* () {
var _a;

@@ -41,2 +41,5 @@ const convert = new ansi_to_html_1.default();

}
if (showAnnotations && showAnnotationsInColumn) {
content.push(`<th>Annotations</th>`);
}
if (showError) {

@@ -59,3 +62,3 @@ content.push(`<th>Error</th>`);

}
if (showAnnotations && test.annotations) {
if (showAnnotations && !showAnnotationsInColumn && test.annotations) {
let colLength = 4;

@@ -86,2 +89,11 @@ if (showTags) {

}
if (showAnnotations && showAnnotationsInColumn) {
const annotations = yield (0, getTestAnnotations_1.getTestAnnotations)(test);
if (annotations) {
testRows.push(`<td>${annotations}</td>`);
}
else {
testRows.push(`<td></td>`);
}
}
if (showError) {

@@ -88,0 +100,0 @@ const error = ((_a = result === null || result === void 0 ? void 0 : result.error) === null || _a === void 0 ? void 0 : _a.message) || "";

import { SummaryTableRow } from "@actions/core/lib/summary";
import { TestCase } from "@playwright/test/reporter";
import { BlobService, DisplayLevel } from "../models";
export declare const getTableRows: (tests: TestCase[], showAnnotations: boolean, showTags: boolean, showError: boolean, displayLevel: DisplayLevel[], blobService?: BlobService) => Promise<SummaryTableRow[]>;
export declare const getTableRows: (tests: TestCase[], showAnnotations: boolean, showTags: boolean, showError: boolean, displayLevel: DisplayLevel[], showAnnotationsInColumn?: boolean, blobService?: BlobService) => Promise<SummaryTableRow[]>;

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

const processAttachments_1 = require("./processAttachments");
const getTableRows = (tests, showAnnotations, showTags, showError, displayLevel, blobService) => __awaiter(void 0, void 0, void 0, function* () {
const getTableRows = (tests, showAnnotations, showTags, showError, displayLevel, showAnnotationsInColumn = false, blobService) => __awaiter(void 0, void 0, void 0, function* () {
var _a;

@@ -53,2 +53,8 @@ const convert = new ansi_to_html_1.default();

}
if (showAnnotations && showAnnotationsInColumn) {
tableHeaders.push({
data: "Annotations",
header: true,
});
}
if (showError) {

@@ -75,3 +81,3 @@ tableHeaders.push({

}
if (showAnnotations && test.annotations) {
if (showAnnotations && !showAnnotationsInColumn && test.annotations) {
let colLength = 4;

@@ -122,2 +128,17 @@ if (showTags) {

}
if (showAnnotations && showAnnotationsInColumn) {
const annotations = yield (0, getTestAnnotations_1.getTestAnnotations)(test);
if (annotations) {
tableRow.push({
data: annotations,
header: false,
});
}
else {
tableRow.push({
data: "",
header: false,
});
}
}
if (showError) {

@@ -124,0 +145,0 @@ const error = ((_a = result === null || result === void 0 ? void 0 : result.error) === null || _a === void 0 ? void 0 : _a.message) || "";

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

if (options.useDetails) {
const content = yield (0, getHtmlTable_1.getHtmlTable)(tests[filePath], options.showAnnotations, options.showTags, !!options.showError, options.includeResults, blobService);
const content = yield (0, getHtmlTable_1.getHtmlTable)(tests[filePath], options.showAnnotations, options.showTags, !!options.showError, options.includeResults, options.showAnnotationsInColumn, blobService);
if (!content) {

@@ -95,3 +95,3 @@ continue;

else {
const tableRows = yield (0, getTableRows_1.getTableRows)(tests[filePath], options.showAnnotations, options.showTags, !!options.showError, options.includeResults, blobService);
const tableRows = yield (0, getTableRows_1.getTableRows)(tests[filePath], options.showAnnotations, options.showTags, !!options.showError, options.includeResults, options.showAnnotationsInColumn, blobService);
if (tableRows.length !== 0) {

@@ -98,0 +98,0 @@ summary.addHeading((0, getTestHeading_1.getTestHeading)(fileName, os, project), 2);

{
"name": "@estruyf/github-actions-reporter",
"version": "1.10.0-beta.1134598",
"version": "1.10.0-beta.1292628",
"description": "GitHub Actions reporter for Playwright",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

@@ -39,2 +39,3 @@ # GitHub Actions Reporter for Playwright

| showAnnotations | Show annotations from tests | `true` |
| showAnnotationsInColumn | Shows annotations from tests but in a column. To enable showAnnotations must be set to `true` | `false` |
| showTags | Show tags from tests | `true` |

@@ -41,0 +42,0 @@ | showError | Show error message in summary | `false` |