| 1 | export const FUNCTIONS = [ |
| 2 | { |
| 3 | nodeType: "function_definition with argument and return type", |
| 4 | fileName: "python/functions.py", |
| 5 | language: "Python", |
| 6 | cursorPosition: { line: 15, character: 8 }, |
| 7 | definitionPositions: [ |
| 8 | { row: 14, column: 30 }, // Person |
| 9 | { row: 14, column: 42 }, // Address |
| 10 | ], |
| 11 | }, |
| 12 | { |
| 13 | nodeType: |
| 14 | "function_definition with generic argument and generic return type", |
| 15 | fileName: "python/functions.py", |
| 16 | language: "Python", |
| 17 | cursorPosition: { line: 18, character: 8 }, |
| 18 | definitionPositions: [ |
| 19 | { row: 17, column: 35 }, // Group |
| 20 | { row: 17, column: 42 }, // Person |
| 21 | { row: 17, column: 53 }, // Group |
| 22 | { row: 17, column: 61 }, // Address |
| 23 | ], |
| 24 | }, |
| 25 | { |
| 26 | nodeType: "function_definition with single argument and None return type", |
| 27 | fileName: "python/functions.py", |
| 28 | language: "Python", |
| 29 | cursorPosition: { line: 21, character: 8 }, |
| 30 | definitionPositions: [ |
| 31 | { row: 20, column: 29 }, // Person |
| 32 | ], |
| 33 | }, |
| 34 | { |
| 35 | nodeType: "function_definition with no arguments and single return type", |
| 36 | fileName: "python/functions.py", |
| 37 | language: "Python", |
| 38 | cursorPosition: { line: 24, character: 8 }, |
| 39 | definitionPositions: [ |
| 40 | { row: 23, column: 38 }, // Address |
| 41 | ], |
| 42 | }, |
| 43 | { |
| 44 | nodeType: "function_definition with Union arguments and Union return type", |
| 45 | fileName: "python/functions.py", |
| 46 | language: "Python", |
| 47 | cursorPosition: { line: 27, character: 8 }, |
| 48 | definitionPositions: [ |
| 49 | { row: 26, column: 45 }, // Person |
| 50 | { row: 26, column: 54 }, // Address |
| 51 | { row: 26, column: 72 }, // Person |
| 52 | { row: 26, column: 81 }, // Address |
| 53 | ], |
| 54 | }, |
| 55 | { |
| 56 | nodeType: |
| 57 | "function_definition with multiple arguments and None return type", |
| 58 | fileName: "python/functions.py", |
| 59 | language: "Python", |
| 60 | cursorPosition: { line: 30, character: 8 }, |
| 61 | definitionPositions: [ |
| 62 | { row: 29, column: 41 }, // Person |
| 63 | { row: 29, column: 59 }, // Address |
| 64 | ], |
| 65 | }, |
| 66 | { |
| 67 | nodeType: "function_definition with one argument and Generator return type", |
| 68 | fileName: "python/functions.py", |
| 69 | language: "Python", |
| 70 | cursorPosition: { line: 33, character: 9 }, |
| 71 | definitionPositions: [ |
| 72 | { row: 32, column: 40 }, // Person |
| 73 | { row: 32, column: 62 }, // Address |
| 74 | ], |
| 75 | }, |
| 76 | { |
| 77 | nodeType: "function_definition inside a class", |
| 78 | fileName: "python/functions.py", |
| 79 | language: "Python", |
| 80 | cursorPosition: { line: 38, character: 12 }, |
| 81 | definitionPositions: [ |
| 82 | { row: 37, column: 51 }, // Person |
| 83 | { row: 37, column: 69 }, // Address |
| 84 | ], |
| 85 | }, |
| 86 | { |
| 87 | nodeType: "function_definition of an async function", |
| 88 | fileName: "python/functions.py", |
| 89 | language: "Python", |
| 90 | cursorPosition: { line: 41, character: 8 }, |
| 91 | definitionPositions: [ |
| 92 | { row: 40, column: 37 }, // Address |
| 93 | { row: 40, column: 48 }, // Person |
| 94 | ], |
| 95 | }, |
| 96 | ]; |
| 97 | |
| 98 | export const CLASSES = [ |
| 99 | { |
| 100 | nodeType: "class_definition with multiple superclasses", |
| 101 | fileName: "python/classes.py", |
| 102 | language: "Python", |
| 103 | cursorPosition: { line: 1, character: 8 }, |
| 104 | definitionPositions: [ |
| 105 | { row: 0, column: 21 }, // BaseClass |
| 106 | { row: 0, column: 29 }, // Person |
| 107 | ], |
| 108 | }, |
| 109 | { |
| 110 | nodeType: "class_definition with multiple superclasses", |
| 111 | fileName: "python/classes.py", |
| 112 | language: "Python", |
| 113 | cursorPosition: { line: 4, character: 8 }, |
| 114 | definitionPositions: [ |
| 115 | { row: 3, column: 31 }, // MetaGroup |
| 116 | ], |
| 117 | }, |
| 118 | { |
| 119 | nodeType: "class_definition with generic superclasses", |
| 120 | fileName: "python/classes.py", |
| 121 | language: "Python", |
| 122 | cursorPosition: { line: 7, character: 8 }, |
| 123 | definitionPositions: [ |
| 124 | { row: 6, column: 21 }, // BaseClass |
| 125 | { row: 6, column: 29 }, // Address |
| 126 | { row: 6, column: 41 }, // Gathering |
| 127 | { row: 6, column: 48 }, // Person |
| 128 | ], |
| 129 | }, |
| 130 | { |
| 131 | nodeType: "class_definition with generic superclasses (built in types)", |
| 132 | fileName: "python/classes.py", |
| 133 | language: "Python", |
| 134 | cursorPosition: { line: 10, character: 8 }, |
| 135 | definitionPositions: [ |
| 136 | { row: 9, column: 24 }, // Address |
| 137 | { row: 9, column: 33 }, // Person |
| 138 | ], |
| 139 | }, |
| 140 | ]; |
| 141 | |
| 142 | export const PYTHON_TEST_CASES = [ |
| 143 | // ...FUNCTIONS, |
| 144 | ...CLASSES, |
| 145 | ]; |