

def test_is_directed_acyclic_graph(self):
    G = nx.generators.complete_graph(2)
    assert_false(nx.is_directed_acyclic_graph(G))
    assert_false(nx.is_directed_acyclic_graph(G.to_directed()))
    assert_false(nx.is_directed_acyclic_graph(nx.Graph([(3, 4), (4, 5)])))
    assert_true(nx.is_directed_acyclic_graph(nx.DiGraph([(3, 4), (4, 5)])))

dataset/ETHPy150Open gkno/gkno_launcher/src/networkx/algorithms/tests/test_dag.py TestDAG.test_is_directed_acyclic_graph/original