Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
// Polyfills
import {debug} from "../../../ts/src/debug";
const global = Function('return this')();
if (typeof Uint8Array === "undefined") {
(global as any).Uint8Array = require("typedarray").Uint8Array;
}
if (typeof ArrayBuffer === "undefined") {
(global as any).ArrayBuffer = require("typedarray").ArrayBuffer;
}
if (typeof DataView === "undefined") {
(global as any).DataView = require("typedarray").DataView;
}
// Test Config
import {assert} from "chai";
import {
testHost,
corsHost
} from "../../hosts-config";
type TestConfig = {
testHostUrl: string,
corsHostUrl: string,
unavailableHost: string,
emptyHost: string,
}
const http1Config: TestConfig = {
testHostUrl: `https://${testHost}:9100`,