js-libp2p-noise/test/noise.test.ts

13 lines
348 B
TypeScript
Raw Normal View History

2019-11-11 15:39:09 +01:00
import { expect } from "chai";
import { Noise } from "../src";
import {generateEd25519Keys} from "./utils";
describe("Noise", () => {
2019-11-11 21:58:04 +01:00
it("should encrypt outgoing data using secureOutbound", async() => {
2019-11-11 15:39:09 +01:00
const libp2pKeys = await generateEd25519Keys();
const noise = new Noise(libp2pKeys._key);
2019-11-11 21:58:04 +01:00
await noise.secureOutbound();
2019-11-11 15:39:09 +01:00
})
});