playwright-notion-reporter 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md ADDED
@@ -0,0 +1,131 @@
1
+ # playwright-notion-reporter
2
+
3
+ A [Playwright reporter](https://playwright.dev/docs/test-reporters) that creates a row in a Notion database after each test run with pass/fail counts, flaky test detection, and optional metadata columns.
4
+
5
+ ## Installation
6
+
7
+ ```bash
8
+ npm install playwright-notion-reporter
9
+ ```
10
+
11
+ ## Notion setup
12
+
13
+ 1. Create a [Notion integration](https://www.notion.so/my-integrations) and copy the **Internal Integration Secret**.
14
+ 2. Create a database for test runs and share it with your integration.
15
+ 3. Copy the database ID from the database URL (`https://notion.so/{workspace}/{database_id}?v=...`).
16
+
17
+ Your database needs properties that match the column names you configure below. The reporter writes these property types automatically:
18
+
19
+ | Config key | Notion property type | Description |
20
+ |---|---|---|
21
+ | `passed`, `failed`, `skipped`, `flaky`, `total` | Number | Test counts |
22
+ | `duration` (optional) | Number | Total run duration in seconds |
23
+ | `status` (optional) | Select | `Passed` or `Failed` — create both options in Notion |
24
+ | `columns` entries | Depends on `type` | See [Custom columns](#custom-columns) |
25
+
26
+ Property names must match your Notion column names exactly.
27
+
28
+ ## Usage
29
+
30
+ Add the reporter to `playwright.config.ts`:
31
+
32
+ ```ts
33
+ import { defineConfig } from '@playwright/test';
34
+
35
+ export default defineConfig({
36
+ reporter: [
37
+ ['list'],
38
+ [
39
+ 'playwright-notion-reporter',
40
+ {
41
+ apiKey: process.env.NOTION_API_KEY!,
42
+ databaseId: process.env.NOTION_DATABASE_ID!,
43
+ statusColumns: {
44
+ passed: 'Passed',
45
+ failed: 'Failed',
46
+ skipped: 'Skipped',
47
+ flaky: 'Flaky',
48
+ total: 'Total',
49
+ duration: 'Duration',
50
+ status: 'Status',
51
+ },
52
+ columns: [
53
+ {
54
+ column_name: 'Branch',
55
+ value: process.env.GITHUB_REF_NAME,
56
+ type: 'rich_text',
57
+ },
58
+ {
59
+ column_name: 'Run URL',
60
+ value: process.env.GITHUB_SERVER_URL
61
+ ? `${process.env.GITHUB_SERVER_URL}/${process.env.GITHUB_REPOSITORY}/actions/runs/${process.env.GITHUB_RUN_ID}`
62
+ : undefined,
63
+ type: 'url',
64
+ },
65
+ ],
66
+ },
67
+ ],
68
+ ],
69
+ });
70
+ ```
71
+
72
+ Store secrets in environment variables — never commit your Notion API key.
73
+
74
+ If `apiKey` or `databaseId` is missing, the reporter logs a message and skips the Notion request without failing the test run.
75
+
76
+ ## Configuration
77
+
78
+ ### `NotionReporterOptions`
79
+
80
+ | Option | Type | Required | Description |
81
+ |---|---|---|---|
82
+ | `apiKey` | `string` | Yes | Notion integration token |
83
+ | `databaseId` | `string` | Yes | Target Notion database ID |
84
+ | `statusColumns` | `NotionStatusColumns` | Yes | Maps computed values to Notion property names |
85
+ | `columns` | `NotionColumn[]` | No | Extra metadata columns; skipped when `value` is empty |
86
+
87
+ ### `statusColumns`
88
+
89
+ | Key | Required | Notion type | Description |
90
+ |---|---|---|---|
91
+ | `passed` | Yes | Number | Tests that passed on the first attempt |
92
+ | `failed` | Yes | Number | Tests that failed, timed out, or were interrupted |
93
+ | `skipped` | Yes | Number | Skipped tests |
94
+ | `flaky` | Yes | Number | Tests that passed after at least one retry |
95
+ | `total` | Yes | Number | Sum of passed, failed, skipped, and flaky |
96
+ | `duration` | No | Number | Run duration in seconds |
97
+ | `status` | No | Select | Overall outcome: `Passed` or `Failed` |
98
+
99
+ ### Custom columns
100
+
101
+ Each entry in `columns` has:
102
+
103
+ | Field | Type | Description |
104
+ |---|---|---|
105
+ | `column_name` | `string` | Notion property name |
106
+ | `value` | `string \| undefined` | Value to write; omitted when falsy |
107
+ | `type` | `NotionPropertyType` | Defaults to `rich_text` |
108
+
109
+ Supported `type` values: `title`, `rich_text`, `select`, `date`, `url`.
110
+
111
+ ## How counts are computed
112
+
113
+ - **Passed** — final attempt status is `passed` with no retries.
114
+ - **Flaky** — final attempt status is `passed` after one or more retries.
115
+ - **Failed** — final attempt status is `failed`, `timedOut`, or `interrupted`.
116
+ - **Skipped** — final attempt status is `skipped`.
117
+
118
+ Only the last attempt per test is counted.
119
+
120
+ ## Development
121
+
122
+ ```bash
123
+ git clone <repo-url>
124
+ cd playwright-notion-reporter
125
+ npm install
126
+ npm run build
127
+ ```
128
+
129
+ ## License
130
+
131
+ ISC
@@ -0,0 +1,44 @@
1
+ import type { FullConfig, FullResult, Reporter, Suite, TestCase, TestResult } from '@playwright/test/reporter';
2
+ export type NotionPropertyType = 'title' | 'rich_text' | 'select' | 'date' | 'url';
3
+ export interface NotionColumn {
4
+ column_name: string;
5
+ value: string | undefined;
6
+ /** Notion property type. Defaults to 'rich_text'. */
7
+ type?: NotionPropertyType;
8
+ }
9
+ /** Column names for values the reporter computes automatically. */
10
+ export interface NotionStatusColumns {
11
+ passed: string;
12
+ failed: string;
13
+ skipped: string;
14
+ flaky: string;
15
+ total: string;
16
+ /** Column for total run duration in seconds. */
17
+ duration?: string;
18
+ /** Column for overall run outcome. Written as a select with value 'Passed' or 'Failed'. */
19
+ status?: string;
20
+ }
21
+ export interface NotionReporterOptions {
22
+ /** Notion integration token passed from reporter config. */
23
+ apiKey: string;
24
+ /** Notion database ID passed from reporter config. */
25
+ databaseId: string;
26
+ /** Column names for the values the reporter computes. */
27
+ statusColumns: NotionStatusColumns;
28
+ /** Free-form metadata columns. Skipped when value is empty. */
29
+ columns?: NotionColumn[];
30
+ }
31
+ declare class NotionReporter implements Reporter {
32
+ private readonly options;
33
+ private readonly apiKey;
34
+ private readonly databaseId;
35
+ private startTime;
36
+ private attempts;
37
+ constructor(options: NotionReporterOptions);
38
+ onBegin(_config: FullConfig, _suite: Suite): void;
39
+ onTestEnd(test: TestCase, result: TestResult): void;
40
+ onEnd(result: FullResult): Promise<void>;
41
+ printsToStdio(): boolean;
42
+ }
43
+ export default NotionReporter;
44
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":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AM,EAAE,KAAK,GAAG,IAAI;IAIjD,SAAS,CAAC,IAAI,EAAE,QAAQ,EAAE,MAAM,EAAE,UAAU,GAAG,IAAI;IAK7C,KAAK,CAAC,MAAM,EAAE,UAAU,GAAG,OAAO,CAAC,IAAI,CAAC;IAgG9C,aAAa,IAAI,OAAO;CAGzB;AAED,eAAe,cAAc,CAAC"}
package/dist/index.js ADDED
@@ -0,0 +1,120 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const NOTION_API_VERSION = '2026-03-11';
4
+ const FETCH_TIMEOUT_MS = 10000;
5
+ function toNotionProperty(value, type = 'rich_text') {
6
+ switch (type) {
7
+ case 'title':
8
+ return { title: [{ text: { content: value } }] };
9
+ case 'select':
10
+ return { select: { name: value } };
11
+ case 'date':
12
+ return { date: { start: value } };
13
+ case 'url':
14
+ return { url: value };
15
+ default:
16
+ return { rich_text: [{ text: { content: value } }] };
17
+ }
18
+ }
19
+ class NotionReporter {
20
+ constructor(options) {
21
+ this.startTime = 0;
22
+ this.attempts = new Map();
23
+ this.options = options;
24
+ this.apiKey = options.apiKey;
25
+ this.databaseId = options.databaseId;
26
+ }
27
+ onBegin(_config, _suite) {
28
+ this.startTime = Date.now();
29
+ }
30
+ onTestEnd(test, result) {
31
+ // Always overwrite so only the last attempt per test is counted
32
+ this.attempts.set(test.id, { status: result.status, retry: result.retry });
33
+ }
34
+ async onEnd(result) {
35
+ const { apiKey, databaseId } = this;
36
+ if (!apiKey || !databaseId) {
37
+ console.log('[NotionReporter] Skipped: apiKey or databaseId not provided in reporter config.');
38
+ return;
39
+ }
40
+ const duration = Math.round((Date.now() - this.startTime) / 1000);
41
+ const counts = { passed: 0, failed: 0, skipped: 0, flaky: 0 };
42
+ for (const attempt of this.attempts.values()) {
43
+ if (attempt.status === 'passed' && attempt.retry > 0) {
44
+ counts.flaky++;
45
+ }
46
+ else if (attempt.status === 'passed') {
47
+ counts.passed++;
48
+ }
49
+ else if (attempt.status === 'failed' ||
50
+ attempt.status === 'timedOut' ||
51
+ attempt.status === 'interrupted') {
52
+ counts.failed++;
53
+ }
54
+ else if (attempt.status === 'skipped') {
55
+ counts.skipped++;
56
+ }
57
+ }
58
+ const total = counts.passed + counts.failed + counts.skipped + counts.flaky;
59
+ const runStatus = result.status === 'passed' ? 'Passed' : 'Failed';
60
+ const col = this.options.statusColumns;
61
+ const properties = {
62
+ [col.passed]: { number: counts.passed },
63
+ [col.failed]: { number: counts.failed },
64
+ [col.skipped]: { number: counts.skipped },
65
+ [col.flaky]: { number: counts.flaky },
66
+ [col.total]: { number: total },
67
+ };
68
+ if (col.duration)
69
+ properties[col.duration] = { number: duration };
70
+ if (col.status)
71
+ properties[col.status] = { select: { name: runStatus } };
72
+ for (const column of this.options.columns ?? []) {
73
+ if (column.value) {
74
+ properties[column.column_name] = toNotionProperty(column.value, column.type);
75
+ }
76
+ }
77
+ const abort = new AbortController();
78
+ const timer = setTimeout(() => abort.abort(), FETCH_TIMEOUT_MS);
79
+ try {
80
+ const response = await fetch('https://api.notion.com/v1/pages', {
81
+ method: 'POST',
82
+ headers: {
83
+ Authorization: `Bearer ${apiKey}`,
84
+ 'Content-Type': 'application/json',
85
+ 'Notion-Version': NOTION_API_VERSION,
86
+ },
87
+ body: JSON.stringify({
88
+ parent: { database_id: databaseId },
89
+ properties,
90
+ }),
91
+ signal: abort.signal,
92
+ });
93
+ if (!response.ok) {
94
+ const text = await response.text();
95
+ console.error(`[NotionReporter] Failed to create Notion record: ${response.status} ${text}`);
96
+ }
97
+ else {
98
+ console.log(`[NotionReporter] Test run recorded in Notion ` +
99
+ `(${runStatus}: ${counts.passed} passed, ${counts.failed} failed, ` +
100
+ `${counts.skipped} skipped, ${counts.flaky} flaky — ${total} total).`);
101
+ }
102
+ }
103
+ catch (error) {
104
+ if (error instanceof Error && error.name === 'AbortError') {
105
+ console.error(`[NotionReporter] Request timed out after ${FETCH_TIMEOUT_MS / 1000}s.`);
106
+ }
107
+ else {
108
+ console.error('[NotionReporter] Error posting to Notion:', error);
109
+ }
110
+ }
111
+ finally {
112
+ clearTimeout(timer);
113
+ }
114
+ }
115
+ printsToStdio() {
116
+ return true;
117
+ }
118
+ }
119
+ exports.default = NotionReporter;
120
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;AASA,MAAM,kBAAkB,GAAG,YAAY,CAAC;AACxC,MAAM,gBAAgB,GAAG,KAAM,CAAC;AA6ChC,SAAS,gBAAgB,CACvB,KAAa,EACb,OAA2B,WAAW;IAEtC,QAAQ,IAAI,EAAE,CAAC;QACb,KAAK,OAAO;YACV,OAAO,EAAE,KAAK,EAAE,CAAC,EAAE,IAAI,EAAE,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,CAAC,EAAE,CAAC;QACnD,KAAK,QAAQ;YACX,OAAO,EAAE,MAAM,EAAE,EAAE,IAAI,EAAE,KAAK,EAAE,EAAE,CAAC;QACrC,KAAK,MAAM;YACT,OAAO,EAAE,IAAI,EAAE,EAAE,KAAK,EAAE,KAAK,EAAE,EAAE,CAAC;QACpC,KAAK,KAAK;YACR,OAAO,EAAE,GAAG,EAAE,KAAK,EAAE,CAAC;QACxB;YACE,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,CAAC,EAAE,CAAC;IACzD,CAAC;AACH,CAAC;AAED,MAAM,cAAc;IAOlB,YAAY,OAA8B;QAHlC,cAAS,GAAG,CAAC,CAAC;QACd,aAAQ,GAAG,IAAI,GAAG,EAAuB,CAAC;QAGhD,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;QAC7B,IAAI,CAAC,UAAU,GAAG,OAAO,CAAC,UAAU,CAAC;IACvC,CAAC;IAED,OAAO,CAAC,OAAmB,EAAE,MAAa;QACxC,IA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AAI,KAAK,YAAY,KAAK,IAAI,KAAK,CAAC,IAAI,KAAK,YAAY,EAAE,CAAC;gBAC1D,OAAO,CAAC,KAAK,CACX,4CAA4C,gBAAgB,GAAG,IAAI,IAAI,CACxE,CAAC;YACJ,CAAC;iBAAM,CAAC;gBACN,OAAO,CAAC,KAAK,CAAC,2CAA2C,EAAE,KAAK,CAAC,CAAC;YACpE,CAAC;QACH,CAAC;gBAAS,CAAC;YACT,YAAY,CAAC,KAAK,CAAC,CAAC;QACtB,CAAC;IACH,CAAC;IAED,aAAa;QACX,OAAO,IAAI,CAAC;IACd,CAAC;CACF;AAED,kBAAe,cAAc,CAAC"}
package/package.json ADDED
@@ -0,0 +1,32 @@
1
+ {
2
+ "name": "playwright-notion-reporter",
3
+ "version": "1.0.0",
4
+ "description": "Playwright reporter that records test run results to a Notion database",
5
+ "main": "dist/index.js",
6
+ "types": "dist/index.d.ts",
7
+ "files": [
8
+ "dist"
9
+ ],
10
+ "scripts": {
11
+ "build": "tsc",
12
+ "test": "vitest run",
13
+ "test:watch": "vitest",
14
+ "prepublishOnly": "npm run build"
15
+ },
16
+ "keywords": [
17
+ "playwright",
18
+ "notion",
19
+ "reporter",
20
+ "testing"
21
+ ],
22
+ "author": "Iana Hilario <icd.hilario@gmail.com>",
23
+ "license": "ISC",
24
+ "peerDependencies": {
25
+ "@playwright/test": ">=1.0.0"
26
+ },
27
+ "devDependencies": {
28
+ "@playwright/test": "^1.52.0",
29
+ "typescript": "^5.8.3",
30
+ "vitest": "^3.2.4"
31
+ }
32
+ }