Skip to content

Commit e8c518b

Browse files
authored
Merge pull request #73 from pkgjs/bump
2 parents d5a7deb + 80f9745 commit e8c518b

File tree

6 files changed

+38
-43
lines changed

6 files changed

+38
-43
lines changed

.github/workflows/ci.yaml

+8-17
Original file line numberDiff line numberDiff line change
@@ -9,20 +9,11 @@ on:
99
jobs:
1010

1111
test:
12-
13-
runs-on: ubuntu-latest
14-
15-
strategy:
16-
matrix:
17-
node-version: [ 16, 14, 12, 10 ]
18-
19-
steps:
20-
- uses: actions/checkout@v2
21-
- run: |
22-
git config --global user.name github-actions
23-
git config --global user.email github-actions@github.com
24-
- uses: actions/setup-node@v2
25-
with:
26-
node-version: ${{ matrix.node-version }}
27-
- run: npm install
28-
- run: npm run test
12+
uses: pkgjs/action/.github/workflows/node-test.yaml@v0
13+
with:
14+
post-checkout-steps: |
15+
- name: Set git user to avoid warnings
16+
shell: bash
17+
run: |
18+
git config --global user.name github-actions
19+
git config --global user.email github-actions@github.com

.travis.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
11
language: node_js
22

33
import:
4-
- nodejs/ci-config-travis:lts/gte-10.yml
4+
- nodejs/ci-config-travis:lts/gte-14.yml
55

66
cache:
77
npm: false
88

99
install:
10+
- "npm install -g npm"
1011
- "npm install --ignore-scripts"
1112
- "npx allow-scripts"

package.json

+6-6
Original file line numberDiff line numberDiff line change
@@ -24,27 +24,27 @@
2424
"url": "https://github.com/pkgjs/detect-node-support/issues"
2525
},
2626
"engines": {
27-
"node": ">=10"
27+
"node": ">=14"
2828
},
2929
"homepage": "https://github.com/pkgjs/detect-node-support#readme",
3030
"devDependencies": {
3131
"@hapi/code": "^8.0.0",
3232
"@hapi/lab": "^24.0.0",
3333
"allow-scripts": "^1.5.2",
3434
"nock": "^13.0.0",
35-
"sinon": "^11.0.0"
35+
"sinon": "^13.0.0"
3636
},
3737
"dependencies": {
38-
"@npmcli/arborist": "^2.1.0",
38+
"@npmcli/arborist": "^4.0.0",
3939
"@octokit/plugin-throttling": "^3.2.2",
4040
"@octokit/rest": "^18.0.0",
41-
"@pkgjs/nv": "0.1.0",
41+
"@pkgjs/nv": "0.2.1",
4242
"debug": "^4.1.1",
4343
"git-url-parse": "^11.1.2",
4444
"js-yaml": "^4.0.0",
4545
"minimist": "^1.2.5",
46-
"pacote": "^11.1.0",
47-
"simple-git": "^2.13.1",
46+
"pacote": "^12.0.0",
47+
"simple-git": "^3.0.0",
4848
"tmp": "^0.2.0"
4949
}
5050
}

renovate.json

+4-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
"extends": [
3-
"config:base"
4-
],
5-
"rangeStrategy": "replace"
3+
"config:base",
4+
":preserveSemverRanges",
5+
":disableDependencyDashboard"
6+
]
67
}

test/fixtures/index.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,9 @@ module.exports = class TestContext {
7272

7373
Nock('https://api.github.com')
7474
.persist()
75-
.get('/repos/nodejs/ci-config-travis/contents/lts%2Fgte-10.yml')
75+
.get('/repos/nodejs/ci-config-travis/contents/lts%2Fgte-14.yml')
7676
.reply(200, {
77+
// note: this is mocked out to an earlier version of node, to avoid having to update too many assertions/fixtures
7778
content: Fs.readFileSync(Path.join(__dirname, 'travis-ymls', 'nodejs-ci-config-travis-gte-10.yml')).toString('base64')
7879
});
7980

test/index.js

+16-15
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ describe('detect-node-support', () => {
6262
'14': '14.3.0'
6363
}
6464
},
65-
engines: '>=10'
65+
engines: '>=14'
6666
});
6767
});
6868

@@ -454,7 +454,7 @@ describe('detect-node-support', () => {
454454
'14': '14.3.0'
455455
}
456456
},
457-
engines: '>=10'
457+
engines: '>=14'
458458
});
459459
});
460460

@@ -491,7 +491,7 @@ describe('detect-node-support', () => {
491491
'14': '14.3.0'
492492
}
493493
},
494-
engines: '>=10'
494+
engines: '>=14'
495495
});
496496
});
497497

@@ -518,7 +518,7 @@ describe('detect-node-support', () => {
518518
version: '0.0.0-development',
519519
commit: '9cef39d21ad229dea4b10295f55b0d9a83800b23',
520520
timestamp: 1580673602000,
521-
engines: '>=10'
521+
engines: '>=14'
522522
});
523523
});
524524

@@ -596,7 +596,7 @@ describe('detect-node-support', () => {
596596
content: Fs.readFileSync(Path.join(__dirname, '..', 'package.json')).toString('base64')
597597
})
598598
.get('/repos/pkgjs/detect-node-support/contents/.travis.yml')
599-
.reply(403, null, {
599+
.reply(403, '', {
600600
'x-ratelimit-limit': '60',
601601
'x-ratelimit-remaining': '0',
602602
'x-ratelimit-reset': `${Math.round(Date.now() / 1000) + 1}`
@@ -621,7 +621,7 @@ describe('detect-node-support', () => {
621621
'14': '14.3.0'
622622
}
623623
},
624-
engines: '>=10'
624+
engines: '>=14'
625625
});
626626
});
627627

@@ -635,10 +635,11 @@ describe('detect-node-support', () => {
635635
.reply(200, {
636636
content: Fs.readFileSync(Path.join(__dirname, '..', 'package.json')).toString('base64')
637637
})
638+
// https://docs.github.com/en/rest/overview/resources-in-the-rest-api#secondary-rate-limits
638639
.get('/repos/pkgjs/detect-node-support/contents/.travis.yml')
639-
.reply(403, 'Abuse detected');
640+
.reply(403, 'You have exceeded a secondary rate limit');
640641

641-
await expect(NodeSupport.detect({ repository: 'git+https://github.com/pkgjs/detect-node-support.git' })).to.reject(/Abuse detected/);
642+
await expect(NodeSupport.detect({ repository: 'git+https://github.com/pkgjs/detect-node-support.git' })).to.reject(/You have exceeded a secondary rate limit/);
642643
});
643644
});
644645

@@ -685,7 +686,7 @@ describe('detect-node-support', () => {
685686
'14': '14.3.0'
686687
}
687688
},
688-
engines: '>=10'
689+
engines: '>=14'
689690
});
690691
});
691692

@@ -716,7 +717,7 @@ describe('detect-node-support', () => {
716717
version: '0.0.0-development',
717718
commit: '9cef39d21ad229dea4b10295f55b0d9a83800b23',
718719
timestamp: 1580673602000,
719-
engines: '>=10'
720+
engines: '>=14'
720721
});
721722
});
722723

@@ -814,7 +815,7 @@ describe('detect-node-support', () => {
814815
'14': '14.3.0'
815816
}
816817
},
817-
engines: '>=10'
818+
engines: '>=14'
818819
});
819820
});
820821

@@ -864,7 +865,7 @@ describe('detect-node-support', () => {
864865
'14': '14.3.0'
865866
}
866867
},
867-
engines: '>=10'
868+
engines: '>=14'
868869
});
869870
});
870871

@@ -901,7 +902,7 @@ describe('detect-node-support', () => {
901902
'14': '14.3.0'
902903
}
903904
},
904-
engines: '>=10'
905+
engines: '>=14'
905906
});
906907
});
907908

@@ -938,7 +939,7 @@ describe('detect-node-support', () => {
938939
'14': '14.3.0'
939940
}
940941
},
941-
engines: '>=10'
942+
engines: '>=14'
942943
});
943944
});
944945

@@ -979,7 +980,7 @@ describe('detect-node-support', () => {
979980
'14': '14.3.0'
980981
}
981982
},
982-
engines: '>=10'
983+
engines: '>=14'
983984
});
984985
});
985986

0 commit comments

Comments
 (0)