def test_project_directory_properties(project_dir): project = Project() contracts_dir = get_contracts_dir(project_dir) assert is_same_path(project.contracts_dir, contracts_dir) build_dir = get_build_dir(project_dir) assert is_same_path(project.build_dir, build_dir) compiled_contracts_file_path = get_compiled_contracts_file_path( project_dir) assert is_same_path(project.compiled_contracts_file_path, compiled_contracts_file_path) blockchains_dir = get_blockchains_dir(project_dir) assert is_same_path(project.blockchains_dir, blockchains_dir) data_dir = get_data_dir(project_dir, 'some-test-chain-name') assert is_same_path( project.get_blockchain_data_dir('some-test-chain-name'), data_dir) chaindata_dir = get_chaindata_dir(data_dir) assert is_same_path( project.get_blockchain_chaindata_dir('some-test-chain-name'), chaindata_dir) geth_ipc_path = get_geth_ipc_path(data_dir) assert is_same_path( project.get_blockchain_ipc_path('some-test-chain-name'), geth_ipc_path)
def test_project_directory_properties(project_dir): project = Project() contracts_dir = get_contracts_dir(project_dir) assert is_same_path(project.contracts_dir, contracts_dir) build_dir = get_build_dir(project_dir) assert is_same_path(project.build_dir, build_dir) compiled_contracts_file_path = get_compiled_contracts_file_path(project_dir) assert is_same_path(project.compiled_contracts_file_path, compiled_contracts_file_path) blockchains_dir = get_blockchains_dir(project_dir) assert is_same_path(project.blockchains_dir, blockchains_dir) data_dir = get_data_dir(project_dir, "some-test-chain-name") assert is_same_path(project.get_blockchain_data_dir("some-test-chain-name"), data_dir) chaindata_dir = get_chaindata_dir(data_dir) assert is_same_path(project.get_blockchain_chaindata_dir("some-test-chain-name"), chaindata_dir) geth_ipc_path = get_geth_ipc_path(data_dir) assert is_same_path(project.get_blockchain_ipc_path("some-test-chain-name"), geth_ipc_path)
def get_blockchain_data_dir(self, chain_name): return get_data_dir(self.project_dir, chain_name)