(self)
| 168 | }}) |
| 169 | |
| 170 | def testList(self): |
| 171 | self.maxDiff = None |
| 172 | splootFile = splootFromPython('''x = ['hello', 123]''') |
| 173 | |
| 174 | f = io.StringIO() |
| 175 | f.write = wrapStdout(f.write) |
| 176 | with contextlib.redirect_stdout(f): |
| 177 | cap, _ = executePythonFile(splootFile) |
| 178 | |
| 179 | self.assertEqual(cap, { |
| 180 | 'root': { |
| 181 | 'type': 'PYTHON_FILE', |
| 182 | 'data': { |
| 183 | 'body': [ |
| 184 | { |
| 185 | 'type': 'PYTHON_ASSIGNMENT', |
| 186 | 'data': {'result': "['hello', 123]", 'resultType': 'list'} |
| 187 | } |
| 188 | ] |
| 189 | } |
| 190 | }, |
| 191 | 'detached': {} |
| 192 | }) |
| 193 | |
| 194 | def testExpressionParsing(self): |
| 195 | splootFile = splootFromPython('''print(100 + 10 + 10 + 4 * 3 * 2 + 10 + 10)''') |
nothing calls this directly
no test coverage detected