-
Notifications
You must be signed in to change notification settings - Fork 56
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1709 from ably/release/2.0.0
Release 2.0.0
- Loading branch information
Showing
246 changed files
with
28,546 additions
and
37,133 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
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 |
---|---|---|
|
@@ -17,16 +17,15 @@ jobs: | |
run: > | ||
git config --global url."https://github.com/".insteadOf | ||
ssh://[email protected]/ | ||
- name: Use Node.js 14.x | ||
- name: Use Node.js 20.x | ||
uses: actions/setup-node@v1 | ||
with: | ||
node-version: 14.x | ||
node-version: 20.x | ||
- run: npm ci | ||
- name: Build bundle reports | ||
run: | | ||
mkdir bundle-reports | ||
npm run sourcemap -- --html bundle-reports/index.html | ||
npm run sourcemap:noencryption -- --html bundle-reports/noencryption.html | ||
- uses: aws-actions/configure-aws-credentials@v1 | ||
with: | ||
aws-region: eu-west-2 | ||
|
@@ -37,3 +36,5 @@ jobs: | |
sourcePath: bundle-reports | ||
githubToken: ${{ secrets.GITHUB_TOKEN }} | ||
artifactName: bundle-report | ||
# This step performs some validation and may fail, so it should come after the steps that we want to always execute. | ||
- run: npm run modulereport |
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 |
---|---|---|
|
@@ -14,16 +14,18 @@ jobs: | |
run: > | ||
git config --global url."https://github.com/".insteadOf | ||
ssh://[email protected]/ | ||
- name: Use Node.js 14.x | ||
- name: Use Node.js 20.x | ||
uses: actions/setup-node@v1 | ||
with: | ||
node-version: 14.x | ||
node-version: 20.x | ||
- run: npm ci | ||
- run: npm run lint | ||
- run: npm run format:check | ||
- run: npm run check-closure-compiler | ||
- run: npx tsc --noEmit ably.d.ts build/ably-webworker.min.d.ts | ||
- run: npx tsc --noEmit ably.d.ts modular.d.ts | ||
# for some reason, this doesn't work in CI using `npx attw --pack .` | ||
- run: npm pack | ||
- run: npx attw ably-$(node -e "console.log(require('./package.json').version)").tgz --summary | ||
- run: npx attw ably-$(node -e "console.log(require('./package.json').version)").tgz --summary --exclude-entrypoints 'ably/modular' | ||
# see https://github.com/ably/ably-js/issues/1546 for why we ignore 'false-cjs' currently. | ||
# should remove when switched to auto-generated type declaration files for modular variant of the library. | ||
- run: npx attw ably-$(node -e "console.log(require('./package.json').version)").tgz --summary --entrypoints 'ably/modular' --ignore-rules false-cjs | ||
- run: npm audit --production |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -20,10 +20,10 @@ jobs: | |
run: > | ||
git config --global url."https://github.com/".insteadOf | ||
ssh://[email protected]/ | ||
- name: Use Node.js 16.x | ||
- name: Use Node.js 20.x | ||
uses: actions/setup-node@v1 | ||
with: | ||
node-version: 16.x | ||
node-version: 20.x | ||
- run: npm ci | ||
- name: Install Playwright browsers and dependencies | ||
run: npx playwright install --with-deps | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
name: Test NPM package | ||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
test-npm-package: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
submodules: true | ||
- name: Use Node.js 20.x | ||
uses: actions/setup-node@v1 | ||
with: | ||
node-version: 20.x | ||
- run: npm ci | ||
- run: npm run test:package |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
const config = { | ||
require: ['source-map-support/register', 'test/support/modules_helper.js', 'test/support/test_helper.js'], | ||
file: ['test/support/root_hooks.js'], | ||
reporter: 'test/support/mocha_reporter.js', | ||
}; | ||
|
||
// mocha has a ridiculous issue (https://github.com/mochajs/mocha/issues/4100) that command line | ||
// specs don't override config specs; they are merged instead, so you can't run a single test file | ||
// if you've defined specs in your config. therefore we work around it by only adding specs to the | ||
// config if none are passed as arguments | ||
if (!process.argv.slice(2).some(isTestFile)) { | ||
config.spec = ['test/realtime/*.test.js', 'test/rest/*.test.js']; | ||
} | ||
|
||
function isTestFile(arg) { | ||
return arg.match(/\.test.js$/); | ||
} | ||
|
||
module.exports = config; |
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,5 +1,5 @@ | ||
{ | ||
"trailingComma": "es5", | ||
"trailingComma": "all", | ||
"tabWidth": 2, | ||
"semi": true, | ||
"singleQuote": true, | ||
|
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.