-
Notifications
You must be signed in to change notification settings - Fork 254
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add sendPayloadChecksums config option and implement Bugsnag-Integrit…
…y header (#2221) * set Bugsnag-Integrity header in delivery-fetch * add jest dir to docker copy * try fix testEnvironment path resolution * add jest dir to docker copy * set jest env * set Bugsnag-Integrity header in delivery-xml-http-request * do not use async syntax * handle no promises in ie11 * do not use promise finally * add sendPayloadChecksums to browser * fix types * tidy test suite * add integrity header to delivery-fetch sendSession * add e2e tests for integrity headers * respect sendPayloadChecksums in delivery-fetch * move sendPayloadChecksums to core * add web worker integration tests for sendPayloadChecksums * add e2e tests for integrity header on web workers * update changelog * skip integrity tests on unsupported browsers * rename fixture documents * use ternary * test: ✅ skip integrity check tests in http context --------- Co-authored-by: Dan Skinner <[email protected]> Co-authored-by: Ben Wilson <[email protected]>
- Loading branch information
1 parent
1d81348
commit 2596383
Showing
26 changed files
with
706 additions
and
87 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
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 |
---|---|---|
@@ -0,0 +1,18 @@ | ||
const { TextDecoder, TextEncoder } = require('node:util') | ||
const crypto = require('crypto') | ||
|
||
const JSDOMEnvironment = require('jest-environment-jsdom') | ||
|
||
class FixJSDOMEnvironment extends JSDOMEnvironment { | ||
constructor (...args) { | ||
super(...args) | ||
|
||
this.global.TextEncoder = TextEncoder | ||
this.global.TextDecoder = TextDecoder | ||
this.global.crypto = { | ||
subtle: crypto.webcrypto.subtle | ||
} | ||
} | ||
} | ||
|
||
module.exports = FixJSDOMEnvironment |
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
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.