def get_main_external_repo(): with location_origin_from_python_file( python_file=file_relative_path(__file__, "setup.py"), attribute=main_repo_name(), working_directory=None, location_name=main_repo_location_name(), ).create_test_location() as location: yield location.get_repository(main_repo_name())
def get_main_external_repo(): with RepositoryLocationHandle.create_from_repository_location_origin( location_origin_from_python_file( python_file=file_relative_path(__file__, "setup.py"), attribute=main_repo_name(), working_directory=None, location_name=main_repo_location_name(), )) as handle: yield RepositoryLocation.from_handle(handle).get_repository( main_repo_name())
def test_external_diamond_toposort(): with RepositoryLocationHandle.create_from_repository_location_origin( location_origin_from_python_file( python_file=__file__, attribute="create_diamond_pipeline", working_directory=None, ) ) as handle: repo_location = RepositoryLocation.from_handle(handle) external_repo = next(iter(repo_location.get_repositories().values())) external_pipeline = next(iter(external_repo.get_all_external_pipelines())) assert external_pipeline.solid_names_in_topological_order == [ "A_source", "A", "B", "C", "D", ]