Skip to content

Commit 43dbe6f

Browse files
committed
fix(core): migrated to PNPM
Related tickets: re #2664
1 parent e574dcb commit 43dbe6f

71 files changed

Lines changed: 21518 additions & 17924 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/actions/setup-node/action.yaml

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,21 +6,20 @@ inputs:
66
description: 'Version spec of the version to use. Examples: 12.x, 10.15.1, >=10.15.0.'
77
type: string
88
required: true
9-
npm-install-command:
10-
description: 'Custom npm install command to use'
11-
type: string
12-
required: false
13-
default: 'npm ci'
9+
default: '22.x'
1410

1511
runs:
1612
using: 'composite'
1713
steps:
14+
- name: Install pnpm
15+
uses: pnpm/action-setup@v4
16+
1817
- name: Setup Node
1918
uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4
2019
with:
2120
node-version: ${{ inputs.node-version }}
21+
cache: 'pnpm'
2222

23-
- name: Install Node Modules (${{ inputs.npm-install-command }})
24-
uses: bahmutov/npm-install@v1
25-
with:
26-
install-command: ${{ inputs.npm-install-command }}
23+
- name: Install dependencies
24+
shell: bash
25+
run: pnpm install

.github/workflows/main.yaml

Lines changed: 1 addition & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,6 @@ jobs:
2020
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
2121
- name: Set up Node
2222
uses: ./.github/actions/setup-node
23-
with:
24-
node-version: 22.x
25-
npm-install-command: npm ci
2623
- name: Lint
2724
run: make lint
2825

@@ -34,9 +31,6 @@ jobs:
3431
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
3532
- name: Set up Node
3633
uses: ./.github/actions/setup-node
37-
with:
38-
node-version: 22.x
39-
npm-install-command: make BOOTSTRAP_SCOPE=libs install
4034
- name: Compile
4135
run: make COMPILE_SCOPE=libs compile
4236
- name: Upload compiled libs
@@ -60,9 +54,6 @@ jobs:
6054
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
6155
- name: Set up Node
6256
uses: ./.github/actions/setup-node
63-
with:
64-
node-version: 22.x
65-
npm-install-command: make BOOTSTRAP_SCOPE=@serenity-js install
6657
- name: Download compiled libs
6758
uses: ./.github/actions/download-compressed-artifact
6859
with:
@@ -88,7 +79,6 @@ jobs:
8879
uses: ./.github/actions/setup-node
8980
with:
9081
node-version: 20.x
91-
npm-install-command: make BOOTSTRAP_SCOPE=@serenity-js install
9282
- name: Download compiled libs
9383
uses: ./.github/actions/download-compressed-artifact
9484
with:
@@ -109,7 +99,6 @@ jobs:
10999
uses: ./.github/actions/setup-node
110100
with:
111101
node-version: 18.x
112-
npm-install-command: make BOOTSTRAP_SCOPE=@serenity-js install
113102
- name: Download compiled libs
114103
uses: ./.github/actions/download-compressed-artifact
115104
with:
@@ -128,9 +117,6 @@ jobs:
128117
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
129118
- name: Set up Node
130119
uses: ./.github/actions/setup-node
131-
with:
132-
node-version: 22.x
133-
npm-install-command: make BOOTSTRAP_SCOPE=@serenity-js install
134120
- name: Download compiled libs
135121
uses: ./.github/actions/download-compressed-artifact
136122
with:
@@ -160,9 +146,6 @@ jobs:
160146
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
161147
- name: Set up Node
162148
uses: ./.github/actions/setup-node
163-
with:
164-
node-version: 22.x
165-
npm-install-command: make BOOTSTRAP_SCOPE=@integration install
166149
- name: Download compiled libs
167150
uses: ./.github/actions/download-compressed-artifact
168151
with:
@@ -195,9 +178,6 @@ jobs:
195178
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
196179
- name: Set up Node
197180
uses: ./.github/actions/setup-node
198-
with:
199-
node-version: 22.x
200-
npm-install-command: make BOOTSTRAP_SCOPE=@integration install
201181
- name: Download compiled libs
202182
uses: ./.github/actions/download-compressed-artifact
203183
with:
@@ -233,9 +213,6 @@ jobs:
233213
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
234214
- name: Set up Node
235215
uses: ./.github/actions/setup-node
236-
with:
237-
node-version: 22.x
238-
npm-install-command: make BOOTSTRAP_SCOPE=@integration install
239216
- name: Download compiled libs
240217
uses: ./.github/actions/download-compressed-artifact
241218
with:
@@ -280,9 +257,6 @@ jobs:
280257
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
281258
- name: Set up Node
282259
uses: ./.github/actions/setup-node
283-
with:
284-
node-version: 22.x
285-
npm-install-command: make BOOTSTRAP_SCOPE=@integration install
286260
- name: Download compiled libs
287261
uses: ./.github/actions/download-compressed-artifact
288262
with:
@@ -319,9 +293,6 @@ jobs:
319293

320294
- name: Set up Node
321295
uses: ./.github/actions/setup-node
322-
with:
323-
node-version: 22.x
324-
npm-install-command: npm ci
325296

326297
- name: Download all artifacts
327298
uses: actions/download-artifact@9bc31d5ccc31df68ecc42ccf4149144866c47d8a # v3
@@ -392,14 +363,7 @@ jobs:
392363
run: 7z x -aoa compiled-libs.zip
393364

394365
- name: Set up Node
395-
uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4
396-
with:
397-
node-version: 22.x
398-
399-
- name: Install Node Modules (root)
400-
uses: bahmutov/npm-install@v1
401-
with:
402-
install-command: npm ci
366+
uses: ./.github/actions/setup-node
403367

404368
- name: Publish artifacts
405369
run: npm run lerna:publish

.npmrc

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
link-workspace-packages = deep
2+
hoist-workspace-packages = true
3+
disallow-workspace-cycles = true
4+
5+
; Cucumber dependencies
6+
hoist-pattern[]=!@types/cucumber
7+
hoist-pattern[]=!@cucumber/*
8+
hoist-pattern[]=!cucumber
9+
hoist-pattern[]=!gherkin
10+
11+
hoist-pattern[]=!@types/jasmine
12+
hoist-pattern[]=!jasmine
13+
hoist-pattern[]=!webdriverio
14+
hoist-pattern[]=!@wdio/*
15+
hoist-pattern[]=!protractor
16+
hoist-pattern[]=!selenium-webdriver

Makefile

Lines changed: 10 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,3 @@
1-
# all
2-
# libs
3-
# site
4-
# @serenity-js
5-
# @integration
6-
# @examples
7-
BOOTSTRAP_SCOPE=all
8-
91
# all
102
# libs
113
# @serenity-js
@@ -41,36 +33,32 @@ INTEGRATION_SCOPE=all
4133
.PHONY: all install clean lint test compile integration-test verify report
4234
all: install clean compile
4335

44-
reinstall:
45-
npm install
46-
npm run lerna:bootstrap:all
47-
4836
install:
49-
npm ci
50-
npm run lerna:bootstrap:$(BOOTSTRAP_SCOPE)
37+
corepack enable
38+
pnpm install
5139

5240
cc:
53-
npm run cc
41+
pnpm cc
5442

5543
clean:
56-
npm run clean
44+
pnpm clean
5745

5846
lint:
59-
npm run lint
47+
pnpm lint
6048

6149
test:
62-
npm test
50+
pnpm test
6351

6452
test-no-coverage:
65-
npm run test:no-coverage
53+
pnpm test:no-coverage
6654

6755
compile:
68-
npm run compile:$(COMPILE_SCOPE)
56+
pnpm compile:$(COMPILE_SCOPE)
6957

7058
integration-test:
71-
npm run integration-test:$(INTEGRATION_SCOPE)
59+
pnpm integration-test:$(INTEGRATION_SCOPE)
7260

7361
verify: lint compile test integration-test
7462

7563
report:
76-
npm run report
64+
pnpm report

examples/cucumber-domain-level-testing/package.json

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -35,13 +35,13 @@
3535
},
3636
"devDependencies": {
3737
"@cucumber/cucumber": "10.9.0",
38-
"@examples/calculator-app": "3.0.0",
39-
"@serenity-js/assertions": "^3.0.0",
40-
"@serenity-js/console-reporter": "^3.0.0",
41-
"@serenity-js/core": "^3.0.0",
42-
"@serenity-js/cucumber": "^3.0.0",
43-
"@serenity-js/rest": "^3.0.0",
44-
"@serenity-js/serenity-bdd": "^3.0.0",
38+
"@examples/calculator-app": "workspace:*",
39+
"@serenity-js/assertions": "workspace:*",
40+
"@serenity-js/console-reporter": "workspace:*",
41+
"@serenity-js/core": "workspace:*",
42+
"@serenity-js/cucumber": "workspace:*",
43+
"@serenity-js/rest": "workspace:*",
44+
"@serenity-js/serenity-bdd": "workspace:*",
4545
"@types/chai": "4.3.20",
4646
"npm-failsafe": "1.3.0",
4747
"ts-node": "10.9.2",

examples/cucumber-reporting/package.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -35,12 +35,12 @@
3535
},
3636
"devDependencies": {
3737
"@cucumber/cucumber": "10.9.0",
38-
"@serenity-js/assertions": "^3.0.0",
39-
"@serenity-js/console-reporter": "^3.0.0",
40-
"@serenity-js/core": "^3.0.0",
41-
"@serenity-js/cucumber": "^3.0.0",
42-
"@serenity-js/rest": "^3.0.0",
43-
"@serenity-js/serenity-bdd": "^3.0.0",
38+
"@serenity-js/assertions": "workspace:*",
39+
"@serenity-js/console-reporter": "workspace:*",
40+
"@serenity-js/core": "workspace:*",
41+
"@serenity-js/cucumber": "workspace:*",
42+
"@serenity-js/rest": "workspace:*",
43+
"@serenity-js/serenity-bdd": "workspace:*",
4444
"@types/chai": "4.3.20",
4545
"npm-failsafe": "1.3.0",
4646
"ts-node": "10.9.2",

examples/cucumber-rest-api-level-testing/package.json

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -35,14 +35,14 @@
3535
},
3636
"devDependencies": {
3737
"@cucumber/cucumber": "10.9.0",
38-
"@examples/calculator-app": "3.0.0",
39-
"@serenity-js/assertions": "^3.0.0",
40-
"@serenity-js/console-reporter": "^3.0.0",
41-
"@serenity-js/core": "^3.0.0",
42-
"@serenity-js/cucumber": "^3.0.0",
43-
"@serenity-js/local-server": "^3.0.0",
44-
"@serenity-js/rest": "^3.0.0",
45-
"@serenity-js/serenity-bdd": "^3.0.0",
38+
"@examples/calculator-app": "workspace:*",
39+
"@serenity-js/assertions": "workspace:*",
40+
"@serenity-js/console-reporter": "workspace:*",
41+
"@serenity-js/core": "workspace:*",
42+
"@serenity-js/cucumber": "workspace:*",
43+
"@serenity-js/local-server": "workspace:*",
44+
"@serenity-js/rest": "workspace:*",
45+
"@serenity-js/serenity-bdd": "workspace:*",
4646
"@types/chai": "4.3.20",
4747
"@types/express": "4.17.21",
4848
"@types/mocha": "10.0.10",

examples/jasmine-rest-api-level-testing/package.json

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -34,14 +34,14 @@
3434
"node": "^18.12 || ^20 || ^22"
3535
},
3636
"devDependencies": {
37-
"@examples/calculator-app": "3.0.0",
38-
"@serenity-js/assertions": "^3.0.0",
39-
"@serenity-js/console-reporter": "^3.0.0",
40-
"@serenity-js/core": "^3.0.0",
41-
"@serenity-js/jasmine": "^3.0.0",
42-
"@serenity-js/local-server": "^3.0.0",
43-
"@serenity-js/rest": "^3.0.0",
44-
"@serenity-js/serenity-bdd": "^3.0.0",
37+
"@examples/calculator-app": "workspace:*",
38+
"@serenity-js/assertions": "workspace:*",
39+
"@serenity-js/console-reporter": "workspace:*",
40+
"@serenity-js/core": "workspace:*",
41+
"@serenity-js/jasmine": "workspace:*",
42+
"@serenity-js/local-server": "workspace:*",
43+
"@serenity-js/rest": "workspace:*",
44+
"@serenity-js/serenity-bdd": "workspace:*",
4545
"@types/chai": "4.3.20",
4646
"@types/jasmine": "5.1.5",
4747
"jasmine": "5.5.0",

examples/mocha-rest-api-level-testing/package.json

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -34,14 +34,14 @@
3434
"node": "^18.12 || ^20 || ^22"
3535
},
3636
"devDependencies": {
37-
"@examples/calculator-app": "3.0.0",
38-
"@serenity-js/assertions": "^3.0.0",
39-
"@serenity-js/console-reporter": "^3.0.0",
40-
"@serenity-js/core": "^3.0.0",
41-
"@serenity-js/local-server": "^3.0.0",
42-
"@serenity-js/mocha": "^3.0.0",
43-
"@serenity-js/rest": "^3.0.0",
44-
"@serenity-js/serenity-bdd": "^3.0.0",
37+
"@examples/calculator-app": "workspace:*",
38+
"@serenity-js/assertions": "workspace:*",
39+
"@serenity-js/console-reporter": "workspace:*",
40+
"@serenity-js/core": "workspace:*",
41+
"@serenity-js/local-server": "workspace:*",
42+
"@serenity-js/mocha": "workspace:*",
43+
"@serenity-js/rest": "workspace:*",
44+
"@serenity-js/serenity-bdd": "workspace:*",
4545
"@types/chai": "4.3.20",
4646
"@types/mocha": "10.0.10",
4747
"mocha": "11.0.1",

examples/playwright-test-todomvc/package.json

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -32,14 +32,14 @@
3232
},
3333
"devDependencies": {
3434
"@playwright/test": "1.49.1",
35-
"@serenity-js/assertions": "^3.0.0",
36-
"@serenity-js/core": "^3.0.0",
37-
"@serenity-js/console-reporter": "^3.0.0",
38-
"@serenity-js/playwright": "^3.0.0",
39-
"@serenity-js/playwright-test": "^3.0.0",
40-
"@serenity-js/rest": "^3.0.0",
41-
"@serenity-js/serenity-bdd": "^3.0.0",
42-
"@serenity-js/web": "^3.0.0",
35+
"@serenity-js/assertions": "workspace:*",
36+
"@serenity-js/core": "workspace:*",
37+
"@serenity-js/console-reporter": "workspace:*",
38+
"@serenity-js/playwright": "workspace:*",
39+
"@serenity-js/playwright-test": "workspace:*",
40+
"@serenity-js/rest": "workspace:*",
41+
"@serenity-js/serenity-bdd": "workspace:*",
42+
"@serenity-js/web": "workspace:*",
4343
"rimraf": "6.0.1"
4444
}
4545
}

0 commit comments

Comments
 (0)