(self, r)
| 52 | |
| 53 | @pytest.mark.onlynoncluster |
| 54 | def test_function_list(self, r): |
| 55 | r.function_load(f"#!{engine} name={lib} \n {function}") |
| 56 | res = [ |
| 57 | [ |
| 58 | b"library_name", |
| 59 | b"mylib", |
| 60 | b"engine", |
| 61 | b"LUA", |
| 62 | b"functions", |
| 63 | [[b"name", b"myfunc", b"description", None, b"flags", [b"no-writes"]]], |
| 64 | ] |
| 65 | ] |
| 66 | resp3_res = [ |
| 67 | { |
| 68 | b"library_name": b"mylib", |
| 69 | b"engine": b"LUA", |
| 70 | b"functions": [ |
| 71 | {b"name": b"myfunc", b"description": None, b"flags": [b"no-writes"]} |
| 72 | ], |
| 73 | } |
| 74 | ] |
| 75 | assert_resp_response(r, r.function_list(), res, resp3_res) |
| 76 | assert_resp_response(r, r.function_list(library="*lib"), res, resp3_res) |
| 77 | res[0].extend( |
| 78 | [b"library_code", f"#!{engine} name={lib} \n {function}".encode()] |
| 79 | ) |
| 80 | resp3_res[0][b"library_code"] = f"#!{engine} name={lib} \n {function}".encode() |
| 81 | assert_resp_response(r, r.function_list(withcode=True), res, resp3_res) |
| 82 | |
| 83 | @pytest.mark.onlycluster |
| 84 | def test_function_list_on_cluster(self, r): |
nothing calls this directly
no test coverage detected