-
Notifications
You must be signed in to change notification settings - Fork 316
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* git commit -m "Handles ngrok v2 and v3 ways of setting the auth token. This commit refactors a couple of things too. Mostly it extracts things from the src/process.js file. Neither the version or authtoken commands need the process (they both spawn their own processes briefly), so they had no business colocating. This allowed the setAuthToken function to break out into a few utility functions and make the function more understandable overall. The new src/version.js didn't change much from when it was in src/process.js, but relocating it did allow for removing some requires at the top of src/process.js * feat: adds function to upgrade ngrok config for use with ngrok version 3 * Updates to use ngrok client v3. * Run tests against node 16 and 18 * Updates README. Tries to not run tests twice on a push to a branch with an open PR. * Just run workflow on push * Exposes old default config path, tests that an old style config file throws * Adds test for config upgrade function * It throws an error, that's what is important * Drops support for Node less than 14.2 * Removes package-lock.json from the repo
- Loading branch information
Showing
32 changed files
with
741 additions
and
2,843 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,26 @@ | ||
name: Tests | ||
|
||
on: [push, pull_request] | ||
on: push | ||
|
||
jobs: | ||
test: | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: [ubuntu-latest, windows-latest, macos-latest] | ||
node-version: [10.x, 12.x, 14.x] | ||
node-version: [14.x, 16.x, 18.x] | ||
max-parallel: 1 | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v1 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
- run: npm install | ||
- run: npm test | ||
env: | ||
CI: true | ||
NGROK_AUTHTOKEN_FREE: ${{secrets.NGROK_AUTHTOKEN_FREE}} | ||
NGROK_AUTHTOKEN_PAID: ${{secrets.NGROK_AUTHTOKEN_PAID}} | ||
NGROK_FORCE_TOKENS: ${{secrets.NGROK_FORCE_TOKENS}} | ||
- uses: actions/checkout@v2 | ||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v1 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
- run: npm install | ||
- run: npm test | ||
env: | ||
CI: true | ||
NGROK_AUTHTOKEN_FREE: ${{secrets.NGROK_AUTHTOKEN_FREE}} | ||
NGROK_AUTHTOKEN_PAID: ${{secrets.NGROK_AUTHTOKEN_PAID}} | ||
NGROK_FORCE_TOKENS: ${{secrets.NGROK_FORCE_TOKENS}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,4 +2,5 @@ node_modules/ | |
bin/ | ||
bin/** | ||
bin/ngrok | ||
*.log | ||
*.log | ||
package-lock.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
{ | ||
"require": "./test/setup.js", | ||
"require": ["./test/setup.js", "./test/configSetup.js"], | ||
"reporter": "spec", | ||
"ui": "bdd", | ||
"recursive": true, | ||
"colors": true, | ||
"timeout": 10000, | ||
"slow": 100 | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.