def test_get_my_graphs(): graphspace = GraphSpace('*****@*****.**', 'user1') # response = graphspace.get_public_graphs(tags=['2015-bioinformatics-xtalk', 'kegg-curated-top-rank-FPs']) graphs = graphspace.get_my_graphs() assert all(isinstance(x, Graph) for x in graphs) assert len(graphs) > 0
def test_user_not_authenticated_error(): graphspace = GraphSpace('*****@*****.**', 'WrongPassword') with pytest.raises(errors.UserNotAuthenticated) as err: graphspace.get_my_graphs()
def test_get_my_graphs(): graphspace = GraphSpace('*****@*****.**', 'user1') graphspace.set_api_host('localhost:8000') # response = graphspace.get_public_graphs(tags=['2015-bioinformatics-xtalk', 'kegg-curated-top-rank-FPs']) response = graphspace.get_my_graphs() assert response is not None and len(response['graphs']) > 0