serverless-spy
Version:
CDK-based library for writing elegant integration tests on AWS serverless architecture and an additional web console to monitor events in real time.
12 lines (11 loc) • 336 B
JavaScript
Object.defineProperty(exports, "__esModule", { value: true });
exports.splitStream = void 0;
async function splitStream(stream) {
if (typeof stream.stream === "function") {
stream = stream.stream();
}
const readableStream = stream;
return readableStream.tee();
}
exports.splitStream = splitStream;
;