()
| 254 | |
| 255 | |
| 256 | def test_simple_1d_array_index(): |
| 257 | p = sqlparse.parse('col[1]')[0].tokens |
| 258 | assert len(p) == 1 |
| 259 | assert p[0].get_name() == 'col' |
| 260 | indices = list(p[0].get_array_indices()) |
| 261 | assert len(indices) == 1 # 1-dimensional index |
| 262 | assert len(indices[0]) == 1 # index is single token |
| 263 | assert indices[0][0].value == '1' |
| 264 | |
| 265 | |
| 266 | def test_2d_array_index(): |
nothing calls this directly
no test coverage detected
searching dependent graphs…