Node implements Closeable { public boolean register (Mailbox mailbox, String name) { return moduleMailbox.register(mailbox, name); } @Builder private  Node(@NonNull NodeDescriptor descriptor,
                @NonNull Meta meta,
                @NonNull EpmdClient epmd,
                int creation,
                @NonNull NodeConfig config
  ); RemoteNode lookup(String name); RemoteNode lookup(ErlangPid pid); RemoteNode lookup(NodeDescriptor nodeDescriptor); boolean ping(String name); boolean ping(NodeDescriptor nodeDescriptor); boolean ping(RemoteNode remote); ErlangReference newReference(); ModuleMailbox.NewMailboxBuilder mailbox(); boolean register(Mailbox mailbox, String name); void deregister(String name); Mailbox mailbox(String name); Mailbox mailbox(ErlangPid pid); void remove(Mailbox mailbox); void remove(String name); void remove(ErlangPid pid); Map<ErlangPid, Mailbox> mailboxes(); CompletableFuture<Connection> connectAsync(RemoteNode remote); Connection connect(RemoteNode remote); Connection connect(RemoteNode remote, long timeout, TimeUnit unit); boolean isAvailable(RemoteNode remote); @Override void close();  }
@Test public void register () { val name = createName(); node = Nodes.singleNode(name, true); assertThat(node.newReference()) .isNotNull(); val nodeInfo = node.lookup(name); assertThat(nodeInfo).isNotNull(); SoftAssertions.assertSoftly(softly -> { softly.assertThat(nodeInfo.getPort()) .isNotEqualTo(0); softly.assertThat(nodeInfo.getType()) .isEqualTo(R6_ERLANG); softly.assertThat(nodeInfo.getProtocol()) .isEqualTo(TCP); softly.assertThat(nodeInfo.getHigh()) .isEqualTo(R6); softly.assertThat(nodeInfo.getLow()) .isEqualTo(R6); }); }