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

Method test_parameterized_skip_limit

tests/flow/test_params.py:82–96  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

80 self._assert_resultset_equals_expected(redis_graph.query(query, params), query_info)
81
82 def test_parameterized_skip_limit(self):
83 params = {'skip': 1, 'limit': 1}
84 query = "UNWIND [1,2,3] AS X RETURN X SKIP $skip LIMIT $limit"
85 expected_results = [[2]]
86
87 query_info = QueryInfo(query = query, description="Tests skip limit as params", expected_result = expected_results)
88 self._assert_resultset_equals_expected(redis_graph.query(query, params), query_info)
89
90 # Set one parameter to non-integer value
91 params = {'skip': '1', 'limit': 1}
92 try:
93 redis_graph.query(query, params)
94 assert(False)
95 except redis.exceptions.ResponseError as e:
96 pass
97
98 def test_missing_parameter(self):
99 # Make sure missing parameters are reported back as an error.

Callers

nothing calls this directly

Calls 3

QueryInfoClass · 0.90
queryMethod · 0.45

Tested by

no test coverage detected