chore: Change the first test to use the withValue instead of the empty, easier to understand.

This commit is contained in:
BluJ
2023-02-13 10:38:52 -07:00
parent c685e9e169
commit 8d8cf3b3a4

View File

@@ -15,20 +15,18 @@ test("Pointer", () => {
target: "tor-address"; target: "tor-address";
interface: string; interface: string;
}; };
} = Config.empty() } = Config.withValue(
.addValue( "peer-tor-address",
"peer-tor-address", Value.pointer(
Value.pointer( Pointer.packageTorAddress({
Pointer.packageTorAddress({ name: "Peer Tor Address",
name: "Peer Tor Address", description: "The Tor address of the peer interface",
description: "The Tor address of the peer interface", "package-id": "bitcoind",
"package-id": "bitcoind", interface: "peer",
interface: "peer", warning: null,
warning: null, })
})
)
) )
.build(); ).build();
expect(JSON.stringify(bitcoinPropertiesBuilt)).toEqual( expect(JSON.stringify(bitcoinPropertiesBuilt)).toEqual(
/*json*/ `{ /*json*/ `{
"peer-tor-address": { "peer-tor-address": {