Skip to content

Commit 4241690

Browse files
authored
Update to node 22 (#674)
* node 22 * Update mineflayer.test.js
1 parent 2716ec7 commit 4241690

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

.github/workflows/ci.yml

+6-6
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,10 @@ jobs:
1212

1313
steps:
1414
- uses: actions/checkout@v2
15-
- name: Use Node.js 18.x
15+
- name: Use Node.js 22.x
1616
uses: actions/[email protected]
1717
with:
18-
node-version: 18.x
18+
node-version: 22.x
1919
- run: npm i && npm run lint
2020

2121
PrepareTestedVersions:
@@ -25,10 +25,10 @@ jobs:
2525

2626
steps:
2727
- uses: actions/checkout@v2
28-
- name: Use Node.js 18.x
28+
- name: Use Node.js 22.x
2929
uses: actions/[email protected]
3030
with:
31-
node-version: 18.x
31+
node-version: 22.x
3232
- id: set-matrix
3333
run: |
3434
node -e "
@@ -45,10 +45,10 @@ jobs:
4545

4646
steps:
4747
- uses: actions/checkout@v2
48-
- name: Use Node.js 18.x
48+
- name: Use Node.js 22.x
4949
uses: actions/[email protected]
5050
with:
51-
node-version: 18.x
51+
node-version: 22.x
5252
- name: Install Dependencies
5353
run: npm install
5454
- name: Start Tests

.github/workflows/npm-publish.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
- name: Set up Node.js
1414
uses: actions/setup-node@master
1515
with:
16-
node-version: 18.0.0
16+
node-version: 22.0.0
1717
- id: publish
1818
uses: JS-DevTools/npm-publish@v1
1919
with:

test/mineflayer.test.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ squid.testedVersions.forEach((testedVersion, i) => {
173173
const pos = bot.entity.position.offset(0, -1, 0).floored()
174174
// Set a dirt block below the bot so we can easily dig
175175
bot.chat(`/setblock ${pos.x} ${pos.y} ${pos.z} dirt`)
176-
await once(bot, `blockUpdate:${pos}`, 4000)
176+
await onceWithTimeout(bot, `blockUpdate:${pos}`, 4000)
177177
console.log('Block at', pos, bot.blockAt(pos))
178178

179179
const p = onceWithTimeout(bot2, 'blockUpdate', 4000, (old, now) => {

0 commit comments

Comments
 (0)