MCPcopy Create free account
hub / github.com/RedisGraph/RedisGraph / SingleNodeCycleGraph

Function SingleNodeCycleGraph

tests/unit/test_query_graph.c:147–164  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

145}
146
147QueryGraph *SingleNodeCycleGraph() {
148 // create a disjoint graph
149 // (A)->(A)
150 size_t node_cap = 1;
151 size_t edge_cap = 1;
152
153 // create nodes
154 const char *relation = "R";
155
156 QGNode *A = QGNode_New("A");
157 QGEdge *AA = QGEdge_New(relation, "AA");
158
159 QueryGraph *g = QueryGraph_New(node_cap, edge_cap);
160 QueryGraph_AddNode(g, A);
161 QueryGraph_ConnectNodes(g, A, A, AA);
162
163 return g;
164}
165
166void test_QueryGraphClone() {
167 // create a triangle graph

Callers 1

Calls 5

QGNode_NewFunction · 0.85
QGEdge_NewFunction · 0.85
QueryGraph_NewFunction · 0.85
QueryGraph_AddNodeFunction · 0.85
QueryGraph_ConnectNodesFunction · 0.85

Tested by

no test coverage detected