(code: string)
| 159 | |
| 160 | describe("getStringContent", () => { |
| 161 | function findStringNode(code: string) { |
| 162 | const tree = parsePythonAST(code); |
| 163 | const cursor = tree.cursor(); |
| 164 | while (cursor.next()) { |
| 165 | if (cursor.name === "String" || cursor.name === "FormatString") { |
| 166 | return cursor.node; |
| 167 | } |
| 168 | } |
| 169 | return null; |
| 170 | } |
| 171 | |
| 172 | it("should extract content from triple double-quoted strings", () => { |
| 173 | const code = '"""hello world"""'; |
no test coverage detected
searching dependent graphs…