()
| 69 | |
| 70 | |
| 71 | def test_sanitize_class(): |
| 72 | icode = r"""Following is the code snippet: |
| 73 | ```python |
| 74 | import numpy as np |
| 75 | from numpy import sin, cos |
| 76 | class g(): |
| 77 | def hello_world(): |
| 78 | return 0 |
| 79 | def f(x): |
| 80 | print(g.hello_world()) |
| 81 | return np.tan(x) |
| 82 | ``` |
| 83 | """ |
| 84 | |
| 85 | assert ( |
| 86 | sanitize(icode) |
| 87 | == r"""import numpy as np |
| 88 | from numpy import sin, cos |
| 89 | class g(): |
| 90 | def hello_world(): |
| 91 | return 0 |
| 92 | def f(x): |
| 93 | print(g.hello_world()) |
| 94 | return np.tan(x)""" |
| 95 | ) |
| 96 | |
| 97 | |
| 98 | def test_entrypoint_basic(): |
nothing calls this directly
no test coverage detected