def deploy_raiden_arguments( privkey: str, save_info: Optional[bool], contracts_version: Optional[str], reuse_secret_registry: bool, ) -> List: arguments: List = [ "--private-key", privkey, "--rpc-provider", "rpc_provider" ] if save_info is True: arguments.append("--save-info") elif save_info is False: arguments.append("--no-save-info") if contracts_version_with_max_token_networks(contracts_version): arguments.extend(["--max-token-networks", 1]) if contracts_version: arguments.extend(["--contracts-version", contracts_version]) if reuse_secret_registry: arguments.extend(["--secret-registry-from-deployment-file", "."]) return arguments
def test_contracts_version_with_max_token_networks(version: Optional[str], expectation: bool) -> None: assert contracts_version_with_max_token_networks(version) == expectation