Commands { RequestBuilder getJoinP2PSwarmCommand( String interfaceName, String localIp, String p2pHash, String secretKey, long secretKeyTtlSec, String portRange ) { return new RequestBuilder( P2P_BINDING ) .withCmdArgs( "start", "-dev", interfaceName, "-hash", p2pHash, "-key", secretKey, "-ttl", String.valueOf( secretKeyTtlSec ), "-ip", localIp, "-ports", portRange ) .withTimeout( Common.JOIN_P2P_TIMEOUT_SEC ); }    }
@Test public void testGetJoinP2PSwarmCommand() throws Exception { assertNotNull( commands.getJoinP2PSwarmCommand( INTERFACE_NAME, LOCAL_IP, P2P_HASH, SECRET_KEY, Common.DEFAULT_P2P_SECRET_KEY_TTL_SEC, "0-65535" ) ); }