playwright-cucumber-ts-steps 0.1.1 → 0.1.3

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.
@@ -0,0 +1 @@
1
+ export declare function checkPeerDependencies(dependencies: string[]): void;
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.checkPeerDependencies = checkPeerDependencies;
4
+ function checkPeerDependencies(dependencies) {
5
+ const missing = [];
6
+ for (const dep of dependencies) {
7
+ try {
8
+ require.resolve(dep);
9
+ }
10
+ catch {
11
+ missing.push(dep);
12
+ }
13
+ }
14
+ if (missing.length) {
15
+ console.warn(`\n❌ Missing peer dependencies: ${missing.join(", ")}` +
16
+ `\nPlease install them in your project:\n\n` +
17
+ `npm install --save-dev ${missing.join(" ")}\n`);
18
+ }
19
+ }
package/dist/register.js CHANGED
@@ -1,4 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  // src/register.ts
4
+ const checkPeerDeps_1 = require("./helpers/checkPeerDeps");
5
+ (0, checkPeerDeps_1.checkPeerDependencies)([
6
+ "@cucumber/cucumber",
7
+ "@playwright/test",
8
+ "@faker-js/faker",
9
+ ]);
4
10
  require("./index");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "playwright-cucumber-ts-steps",
3
- "version": "0.1.1",
3
+ "version": "0.1.3",
4
4
  "description": "A collection of reusable Playwright step definitions for Cucumber in TypeScript, designed to streamline end-to-end testing across web, API, and mobile applications.",
5
5
  "type": "commonjs",
6
6
  "main": "dist/index.js",
@@ -47,22 +47,26 @@
47
47
  "visual-testing"
48
48
  ],
49
49
  "author": "qaPaschalE",
50
- "devDependencies": {
50
+ "license": "MIT",
51
+ "bugs": {
52
+ "url": "https://github.com/qaPaschalE/playwright-cucumber-ts-steps/issues"
53
+ },
54
+ "homepage": "https://github.com/qaPaschalE/playwright-cucumber-ts-steps#readme",
55
+ "peerDependencies": {
51
56
  "@cucumber/cucumber": "^11.3.0",
57
+ "@playwright/test": "^1.53.0"
58
+ },
59
+ "dependencies": {
52
60
  "@faker-js/faker": "^9.8.0",
53
- "@playwright/test": "^1.53.0",
54
- "@types/pngjs": "^6.0.5",
55
61
  "dayjs": "^1.11.13",
56
62
  "dotenv-cli": "^8.0.0",
57
63
  "parse": "^6.1.1",
58
64
  "pixelmatch": "^7.1.0",
59
- "pngjs": "^7.0.0",
60
- "ts-node": "^10.9.2",
61
- "typescript": "^5.8.3"
65
+ "pngjs": "^7.0.0"
62
66
  },
63
- "license": "MIT",
64
- "bugs": {
65
- "url": "https://github.com/qaPaschalE/playwright-cucumber-ts-steps/issues"
66
- },
67
- "homepage": "https://github.com/qaPaschalE/playwright-cucumber-ts-steps#readme"
67
+ "devDependencies": {
68
+ "ts-node": "^10.9.2",
69
+ "typescript": "^5.8.3",
70
+ "@types/pngjs": "^6.0.5"
71
+ }
68
72
  }