mirror of
https://github.com/waku-org/js-waku.git
synced 2025-02-20 16:18:21 +00:00
25 lines
566 B
TypeScript
25 lines
566 B
TypeScript
import { expect } from "chai";
|
|
|
|
import { argsToArray, defaultArgs } from "../src/index.js";
|
|
|
|
describe("nwaku", () => {
|
|
it("Correctly serialized arguments", function () {
|
|
const args = defaultArgs();
|
|
Object.assign(args, { portsShift: 42 });
|
|
|
|
const actual = argsToArray(args);
|
|
|
|
const expected = [
|
|
"--listen-address=127.0.0.1",
|
|
"--rpc=true",
|
|
"--relay=false",
|
|
"--rpc-admin=true",
|
|
"--websocket-support=true",
|
|
"--log-level=TRACE",
|
|
"--ports-shift=42",
|
|
];
|
|
|
|
expect(actual).to.deep.equal(expected);
|
|
});
|
|
});
|