

def test_reuse_loadable_terms(self):
    '\n        Test that raw inputs only show up in the dependency graph once.\n        '
    f1 = SomeFactor([SomeDataSet.foo, SomeDataSet.bar])
    f2 = SomeOtherFactor([SomeDataSet.bar, SomeDataSet.buzz])
    graph = TermGraph(to_dict([f1, f2]))
    resolution_order = list(graph.ordered())
    self.assertEqual(len(resolution_order), 6)
    self.assertEqual(len(set(resolution_order)), 6)
    self.check_dependency_order(resolution_order)

dataset/ETHPy150Open quantopian/zipline/tests/pipeline/test_term.py DependencyResolutionTestCase.test_reuse_loadable_terms/original