(self)
| 261 | |
| 262 | |
| 263 | def testImportFrom(self): |
| 264 | self.maxDiff = None |
| 265 | |
| 266 | fileNode = splootFromPython('from random import randint') |
| 267 | self.assertEqual(fileNode, { |
| 268 | 'type': 'PYTHON_FILE', |
| 269 | 'childSets': {'body': [ |
| 270 | { |
| 271 | "type": "PYTHON_STATEMENT", |
| 272 | "childSets": { |
| 273 | "statement": [{ |
| 274 | 'type': 'PYTHON_FROM_IMPORT', |
| 275 | 'childSets': { |
| 276 | 'attrs': [ |
| 277 | {'type': 'PY_IDENTIFIER', 'childSets': {}, 'properties': {'identifier': 'randint'}} |
| 278 | ], |
| 279 | 'module': [ |
| 280 | {'type': 'PYTHON_MODULE_IDENTIFIER', 'childSets': {}, 'properties': {'identifier': 'random'}} |
| 281 | ] |
| 282 | }, |
| 283 | 'properties': {}, |
| 284 | }] |
| 285 | }, |
| 286 | 'properties': {}, |
| 287 | } |
| 288 | ]}, |
| 289 | 'properties': {}, |
| 290 | }) |
| 291 | |
| 292 | def testTuple(self): |
| 293 | self.maxDiff = None |
nothing calls this directly
no test coverage detected