diff --git a/.circleci/config.yml b/.circleci/config.yml index 3cb5f6dd9..1848164cb 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -75,14 +75,14 @@ commands: steps: - restore_cache: keys: - - v1-verified-codemod-repos-{{ checksum "tests/verified_codemods/codemod_data/repo_commits.json" }}-{{.Environment.CIRCLE_NODE_INDEX}}-{{.Environment.CIRCLE_NODE_TOTAL}} + - v1-verified-codemod-repos-{{ checksum "tests/integration/verified_codemods/codemod_data/repo_commits.json" }}-{{.Environment.CIRCLE_NODE_INDEX}}-{{.Environment.CIRCLE_NODE_TOTAL}} - run: command: | uv run --frozen gs codemod clone-repos --verified-codemod-repos --token ${CODEGEN_BOT_GHE_TOKEN} - save_cache: paths: - $GITHUB_WORKSPACE - key: v1-verified-codemod-repos-{{ checksum "tests/verified_codemods/codemod_data/repo_commits.json" }}-{{.Environment.CIRCLE_NODE_INDEX}}-{{.Environment.CIRCLE_NODE_TOTAL}} + key: v1-verified-codemod-repos-{{ checksum "tests/integration/verified_codemods/codemod_data/repo_commits.json" }}-{{.Environment.CIRCLE_NODE_INDEX}}-{{.Environment.CIRCLE_NODE_TOTAL}} build-wheels: parameters: base_packages: @@ -237,7 +237,7 @@ jobs: - fetch-verified-codemods - cache-verified-codemod-repos - run_ats: - default_tests: "tests/codemod/test_verified_codemods.py" + default_tests: "tests/integration/codemod/test_verified_codemods.py" codecov_flags: "smart-tests-codemod" collect_args: --cli-api-key ${PROD_CLI_API_KEY} --token ${CODEGEN_BOT_GHE_TOKEN} ats_collect_args: --cli-api-key=${PROD_CLI_API_KEY},--token=${CODEGEN_BOT_GHE_TOKEN}, @@ -264,7 +264,7 @@ jobs: - clone-repos: extra_repos: false - run_ats: - default_tests: "tests/codemod/test_codemods.py" + default_tests: "tests/integration/codemod/test_codemods.py" codecov_flags: "smart-tests-codemod-oss" collect_args: --size=<> --sync-graph=<> --token ${CODEGEN_BOT_GHE_TOKEN} ats_collect_args: --size=<>,--sync-graph=<>,--token=${CODEGEN_BOT_GHE_TOKEN}, @@ -297,7 +297,7 @@ jobs: if [ "<>" = "true" ]; then EXTRA_REPOS_ARG="--extra-repos=true" fi - PYTEST_ARGS="${EXTRA_REPOS_ARG} --token ${CODEGEN_BOT_GHE_TOKEN} -o junit_suite_name=\"${CIRCLE_JOB}\" tests/codemod/test_parse.py" + PYTEST_ARGS="${EXTRA_REPOS_ARG} --token ${CODEGEN_BOT_GHE_TOKEN} -o junit_suite_name=\"${CIRCLE_JOB}\" tests/integration/codemod/test_parse.py" echo "Running tests with args: $PYTEST_ARGS" TESTS_TO_RUN=$(PYTEST_ARGS=${PYTEST_ARGS} ./.circleci/collect.sh) echo $TESTS_TO_RUN | circleci tests run --command "ulimit -s unlimited; xargs uv run --frozen pytest -n auto ${PYTEST_ARGS}" diff --git a/.gitattributes b/.gitattributes index 940d26028..ef04dbf41 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,6 +1,6 @@ **/expected_diff.txt filter=lfs diff=lfs merge=lfs -text -tests/codemod/repos/extra/*.json filter=lfs diff=lfs merge=lfs -text +tests/integration/codemod/repos/extra/*.json filter=lfs diff=lfs merge=lfs -text **/expected_diff.patch filter=lfs diff=lfs merge=lfs -text -tests/codemod/repos/repos.json filter=lfs diff=lfs merge=lfs -text -tests/verified_codemods/** filter=lfs diff=lfs merge=lfs -text +tests/integration/codemod/repos/repos.json filter=lfs diff=lfs merge=lfs -text +tests/integration/verified_codemods/** filter=lfs diff=lfs merge=lfs -text .github/disallowed-words.txt filter=lfs diff=lfs merge=lfs -text diff --git a/.github/disallowed-words.txt b/.github/disallowed-words.txt index df0f62f31..85618edae 100644 --- a/.github/disallowed-words.txt +++ b/.github/disallowed-words.txt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ac0b7be00533f882fb174c498c27372fa78d3ec2d65c0e885475bf92b43b7303 -size 337 +oid sha256:c47fe11113256de71968b186bd459732c5f29547b9a57275f671502e9ebd8327 +size 328 diff --git a/.gitignore b/.gitignore index 034b58b3f..f51d990ce 100644 --- a/.gitignore +++ b/.gitignore @@ -63,5 +63,5 @@ uv-*.tar.gz graph-sitter-types/out/** graph-sitter-types/typings/** coverage.json -tests/verified_codemods/codemod_data/repo_commits.json +tests/integration/verified_codemods/codemod_data/repo_commits.json diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 7a1d6d6e5..3f435bffd 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -19,7 +19,7 @@ repos: hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.9.4"] - exclude: (src/codemods/eval)|(tests/unit/skills)|(tests/unit/output)|(tests/verified_codemods)|(docs/samples) + exclude: (src/codemods/eval)|(tests/unit/codegen/sdk/skills)|(tests/unit/codegen/sdk/output)|(tests/integration/verified_codemods)|(docs/samples) - repo: https://github.com/MarcoGorelli/cython-lint rev: v0.16.6 diff --git a/CLA.md b/CLA.md index 06791f5f5..a4fc53632 100644 --- a/CLA.md +++ b/CLA.md @@ -11,40 +11,40 @@ 2. **“Contribution”** means any work of authorship (including any modifications or additions) that is intentionally Submitted by You for inclusion in the Project, in any form (including but not limited to source code, documentation, or other materials). 3. **“Submit”** or **“Submitted”** means any act of transferring a Contribution to Codegen, Inc. via pull request, email, or any other method of communication for the purpose of inclusion in the Project. 2. **Grant of Copyright License** - + Subject to the terms and conditions of this CLA, You hereby grant to Codegen, Inc. and to recipients of software distributed by Codegen, Inc.: - + - A perpetual, worldwide, non-exclusive, royalty-free, irrevocable copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, sublicense, and distribute Your Contributions and such derivative works. 3. **Grant of Patent License** - + Subject to the terms and conditions of this CLA, You hereby grant to Codegen, Inc. and to recipients of software distributed by Codegen, Inc. a perpetual, worldwide, non-exclusive, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer Your Contribution, where such license applies only to those patent claims licensable by You that are necessarily infringed by Your Contribution alone or by combination of Your Contribution with the Project to which You Submitted it. - + If any entity institutes patent litigation against You or any other entity (including a cross-claim or counterclaim in a lawsuit) alleging that Your Contribution, or the Project to which You have contributed, directly or indirectly infringes any patent, then any patent licenses granted to that entity under this CLA for that Contribution or Project shall terminate as of the date such litigation is filed. - + 4. **Representations and Warranties** 1. **Original Work**. You represent that each of Your Contributions is an original work of authorship and that You have the necessary rights to grant the licenses under this CLA. 2. **Third-Party Rights**. If Your employer(s) or any third party has rights to intellectual property that You create, You represent that You have received permission to make Contributions on behalf of that employer or third party (or that such employer or third party has waived those rights for Your Contributions). 3. **No Other Agreements**. You represent that You are not aware of any other agreement or obligation that is inconsistent with the rights granted under this CLA. 5. **Disclaimer of Warranty** - + UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING, YOU PROVIDE YOUR CONTRIBUTIONS ON AN **“AS IS”** BASIS, **WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND**, EITHER EXPRESS OR IMPLIED, INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY, OR FITNESS FOR A PARTICULAR PURPOSE. - + 6. **Limitation of Liability** - + IN NO EVENT SHALL CODEGEN, INC. OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE), ARISING IN ANY WAY OUT OF OR IN CONNECTION WITH THIS AGREEMENT, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - + 7. **Subsequent Contributions and Updates** - + You agree that all current and future Contributions to the Project Submitted by You shall be subject to the terms of this CLA. Codegen, Inc. may publish updates to this CLA from time to time; in such case, You may need to agree to new terms before any subsequent Contributions. - + 8. **License Modification Rights** - + You agree that Codegen, Inc. may change the license(s) applicable to the open source project(s) to which Your Contributions relate at Codegen, Inc.’s sole discretion, including without limitation by re-licensing the project(s) and Your Contributions under any other open source or “free” software license, or a commercial or proprietary license of Codegen, Inc.’s choosing. - + 9. **Governing Law** - + This CLA shall be governed by and construed in accordance with the laws of the State of Delaware, without regard to its conflicts of laws provisions. - + 10. **Signature / Electronic Consent** - + By signing or otherwise indicating Your acceptance of this CLA, You acknowledge that You have read and agree to be bound by its terms. If You are signing on behalf of an entity, You represent and warrant that You have the authority to do so. diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index fc901f0c6..03520bf4e 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -45,7 +45,7 @@ uv sync --dev uv run pytest tests/unit -n auto # Codemod tests (tests larger programs) -uv run pytest tests/codemod/test_codemods.py -n auto +uv run pytest tests/integration/codemod/test_codemods.py -n auto ``` ## Pull Request Process diff --git a/pyproject.toml b/pyproject.toml index 70b7d20f1..a594030c6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -196,6 +196,7 @@ pythonVersion = "3.12" enableExperimentalFeatures = true [tool.pytest.ini_options] # addopts = -v +pythonpath = "." norecursedirs = "repos expected" # addopts = -v --cov=app --cov-report=term diff --git a/src/codegen/sdk/testing/models.py b/src/codegen/sdk/testing/models.py index 50dec3633..1ab254573 100644 --- a/src/codegen/sdk/testing/models.py +++ b/src/codegen/sdk/testing/models.py @@ -17,9 +17,9 @@ BASE_TMP_DIR = Path(os.getenv("GITHUB_WORKSPACE", tempfile.gettempdir())) BASE_PATH: Path = Path(__file__).parent.parent.parent.parent.parent -TEST_DIR: Path = BASE_PATH / "tests" / "codemod" +TEST_DIR: Path = BASE_PATH / "tests" / "integration" / "codemod" CODEMOD_PATH: Path = BASE_PATH / "src" / "codemods" -VERIFIED_CODEMOD_DIR: Path = BASE_PATH / "tests" / "verified_codemods" +VERIFIED_CODEMOD_DIR: Path = BASE_PATH / "tests" / "integration" / "verified_codemods" VERIFIED_CODEMOD_DATA_DIR: Path = VERIFIED_CODEMOD_DIR / "codemod_data" VERIFIED_CODEMOD_DIFFS: Path = VERIFIED_CODEMOD_DIR / "verified_codemod_diffs" diff --git a/src/codemods/README.md b/src/codemods/README.md index 4d41de222..ea6eaca11 100644 --- a/src/codemods/README.md +++ b/src/codemods/README.md @@ -3,7 +3,7 @@ Put your codemod in the canonical folder if it is canonical, otherwise put it in misc. You can also add company folders if you wish `{codemod_folder} = src/codemods/{type}/{name}` -`{codemod_tests_folder} = tests/codemod/{type}/{name}` +`{codemod_tests_folder} = tests/integration/codemod/{type}/{name}` ## Repos diff --git a/tests/README.md b/tests/README.md deleted file mode 100644 index 464090415..000000000 --- a/tests/README.md +++ /dev/null @@ -1 +0,0 @@ -# TODO diff --git a/tests/codemod/.gitignore b/tests/integration/codemod/.gitignore similarity index 100% rename from tests/codemod/.gitignore rename to tests/integration/codemod/.gitignore diff --git a/tests/codemod/__init__.py b/tests/integration/codemod/__init__.py similarity index 100% rename from tests/codemod/__init__.py rename to tests/integration/codemod/__init__.py diff --git a/tests/codemod/canonical/add_function_parameter_type_annotations/test_codegen/expected_diff.patch b/tests/integration/codemod/canonical/add_function_parameter_type_annotations/test_codegen/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/add_function_parameter_type_annotations/test_codegen/expected_diff.patch rename to tests/integration/codemod/canonical/add_function_parameter_type_annotations/test_codegen/expected_diff.patch diff --git a/tests/codemod/canonical/add_function_parameter_type_annotations/test_django/expected_diff.patch b/tests/integration/codemod/canonical/add_function_parameter_type_annotations/test_django/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/add_function_parameter_type_annotations/test_django/expected_diff.patch rename to tests/integration/codemod/canonical/add_function_parameter_type_annotations/test_django/expected_diff.patch diff --git a/tests/codemod/canonical/add_internal_to_non_exported_components/test_virtual_coffee/expected_diff.patch b/tests/integration/codemod/canonical/add_internal_to_non_exported_components/test_virtual_coffee/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/add_internal_to_non_exported_components/test_virtual_coffee/expected_diff.patch rename to tests/integration/codemod/canonical/add_internal_to_non_exported_components/test_virtual_coffee/expected_diff.patch diff --git a/tests/codemod/canonical/bang_bang_to_boolean/test_vite/expected_diff.patch.skip b/tests/integration/codemod/canonical/bang_bang_to_boolean/test_vite/expected_diff.patch.skip similarity index 100% rename from tests/codemod/canonical/bang_bang_to_boolean/test_vite/expected_diff.patch.skip rename to tests/integration/codemod/canonical/bang_bang_to_boolean/test_vite/expected_diff.patch.skip diff --git a/tests/codemod/canonical/bang_bang_to_boolean/test_vscode/expected_diff.patch b/tests/integration/codemod/canonical/bang_bang_to_boolean/test_vscode/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/bang_bang_to_boolean/test_vscode/expected_diff.patch rename to tests/integration/codemod/canonical/bang_bang_to_boolean/test_vscode/expected_diff.patch diff --git a/tests/codemod/canonical/built_in_type_annotation/test_mypy/expected_diff.patch b/tests/integration/codemod/canonical/built_in_type_annotation/test_mypy/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/built_in_type_annotation/test_mypy/expected_diff.patch rename to tests/integration/codemod/canonical/built_in_type_annotation/test_mypy/expected_diff.patch diff --git a/tests/codemod/canonical/built_in_type_annotation/test_transformers/expected_diff.patch b/tests/integration/codemod/canonical/built_in_type_annotation/test_transformers/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/built_in_type_annotation/test_transformers/expected_diff.patch rename to tests/integration/codemod/canonical/built_in_type_annotation/test_transformers/expected_diff.patch diff --git a/tests/codemod/canonical/change_component_tag_names/test_cypress/expected_diff.patch b/tests/integration/codemod/canonical/change_component_tag_names/test_cypress/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/change_component_tag_names/test_cypress/expected_diff.patch rename to tests/integration/codemod/canonical/change_component_tag_names/test_cypress/expected_diff.patch diff --git a/tests/codemod/canonical/convert_array_type_to_square_bracket/test_vite/expected_diff.patch b/tests/integration/codemod/canonical/convert_array_type_to_square_bracket/test_vite/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/convert_array_type_to_square_bracket/test_vite/expected_diff.patch rename to tests/integration/codemod/canonical/convert_array_type_to_square_bracket/test_vite/expected_diff.patch diff --git a/tests/codemod/canonical/convert_attribute_to_decorator/test_flask/expected_diff.patch b/tests/integration/codemod/canonical/convert_attribute_to_decorator/test_flask/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/convert_attribute_to_decorator/test_flask/expected_diff.patch rename to tests/integration/codemod/canonical/convert_attribute_to_decorator/test_flask/expected_diff.patch diff --git a/tests/codemod/canonical/convert_comments_to_JSDoc_style/test_vite/expected_diff.patch b/tests/integration/codemod/canonical/convert_comments_to_JSDoc_style/test_vite/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/convert_comments_to_JSDoc_style/test_vite/expected_diff.patch rename to tests/integration/codemod/canonical/convert_comments_to_JSDoc_style/test_vite/expected_diff.patch diff --git a/tests/codemod/canonical/convert_comments_to_JSDoc_style/test_vscode/expected_diff.patch b/tests/integration/codemod/canonical/convert_comments_to_JSDoc_style/test_vscode/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/convert_comments_to_JSDoc_style/test_vscode/expected_diff.patch rename to tests/integration/codemod/canonical/convert_comments_to_JSDoc_style/test_vscode/expected_diff.patch diff --git a/tests/codemod/canonical/convert_docstring_to_google_style/test_django/expected_diff.patch b/tests/integration/codemod/canonical/convert_docstring_to_google_style/test_django/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/convert_docstring_to_google_style/test_django/expected_diff.patch rename to tests/integration/codemod/canonical/convert_docstring_to_google_style/test_django/expected_diff.patch diff --git a/tests/codemod/canonical/convert_docstring_to_google_style/test_requests-oauthlib/expected_diff.patch b/tests/integration/codemod/canonical/convert_docstring_to_google_style/test_requests-oauthlib/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/convert_docstring_to_google_style/test_requests-oauthlib/expected_diff.patch rename to tests/integration/codemod/canonical/convert_docstring_to_google_style/test_requests-oauthlib/expected_diff.patch diff --git a/tests/codemod/canonical/delete_unused_functions/test_papermark/expected_diff.patch b/tests/integration/codemod/canonical/delete_unused_functions/test_papermark/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/delete_unused_functions/test_papermark/expected_diff.patch rename to tests/integration/codemod/canonical/delete_unused_functions/test_papermark/expected_diff.patch diff --git a/tests/codemod/canonical/delete_unused_functions/test_plone/expected_diff.patch b/tests/integration/codemod/canonical/delete_unused_functions/test_plone/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/delete_unused_functions/test_plone/expected_diff.patch rename to tests/integration/codemod/canonical/delete_unused_functions/test_plone/expected_diff.patch diff --git a/tests/codemod/canonical/delete_unused_functions/test_vscode/expected_diff.patch b/tests/integration/codemod/canonical/delete_unused_functions/test_vscode/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/delete_unused_functions/test_vscode/expected_diff.patch rename to tests/integration/codemod/canonical/delete_unused_functions/test_vscode/expected_diff.patch diff --git a/tests/codemod/canonical/emojify_py_files_codemod/test_codegen/expected_diff.patch b/tests/integration/codemod/canonical/emojify_py_files_codemod/test_codegen/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/emojify_py_files_codemod/test_codegen/expected_diff.patch rename to tests/integration/codemod/canonical/emojify_py_files_codemod/test_codegen/expected_diff.patch diff --git a/tests/codemod/canonical/emojify_py_files_codemod/test_vscode/expected_diff.patch b/tests/integration/codemod/canonical/emojify_py_files_codemod/test_vscode/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/emojify_py_files_codemod/test_vscode/expected_diff.patch rename to tests/integration/codemod/canonical/emojify_py_files_codemod/test_vscode/expected_diff.patch diff --git a/tests/codemod/canonical/enum_mover/test_hass/expected_diff.patch b/tests/integration/codemod/canonical/enum_mover/test_hass/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/enum_mover/test_hass/expected_diff.patch rename to tests/integration/codemod/canonical/enum_mover/test_hass/expected_diff.patch diff --git a/tests/codemod/canonical/enum_mover/test_mypy/expected_diff.patch b/tests/integration/codemod/canonical/enum_mover/test_mypy/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/enum_mover/test_mypy/expected_diff.patch rename to tests/integration/codemod/canonical/enum_mover/test_mypy/expected_diff.patch diff --git a/tests/codemod/canonical/insert_arguments_to_decorator/test_codegen/expected_diff.patch b/tests/integration/codemod/canonical/insert_arguments_to_decorator/test_codegen/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/insert_arguments_to_decorator/test_codegen/expected_diff.patch rename to tests/integration/codemod/canonical/insert_arguments_to_decorator/test_codegen/expected_diff.patch diff --git a/tests/codemod/canonical/js_to_esm_codemod/test_deno_rest/expected_diff.patch b/tests/integration/codemod/canonical/js_to_esm_codemod/test_deno_rest/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/js_to_esm_codemod/test_deno_rest/expected_diff.patch rename to tests/integration/codemod/canonical/js_to_esm_codemod/test_deno_rest/expected_diff.patch diff --git a/tests/codemod/canonical/js_to_esm_codemod/test_jchat/expected_diff.patch b/tests/integration/codemod/canonical/js_to_esm_codemod/test_jchat/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/js_to_esm_codemod/test_jchat/expected_diff.patch rename to tests/integration/codemod/canonical/js_to_esm_codemod/test_jchat/expected_diff.patch diff --git a/tests/codemod/canonical/mark_as_internal_codemod/ignore_test_mypy/expected_diff.patch b/tests/integration/codemod/canonical/mark_as_internal_codemod/ignore_test_mypy/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/mark_as_internal_codemod/ignore_test_mypy/expected_diff.patch rename to tests/integration/codemod/canonical/mark_as_internal_codemod/ignore_test_mypy/expected_diff.patch diff --git a/tests/codemod/canonical/mark_as_internal_codemod/test_vscode/expected_diff.patch b/tests/integration/codemod/canonical/mark_as_internal_codemod/test_vscode/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/mark_as_internal_codemod/test_vscode/expected_diff.patch rename to tests/integration/codemod/canonical/mark_as_internal_codemod/test_vscode/expected_diff.patch diff --git a/tests/codemod/canonical/mark_internal_to_module/test_codegen/expected_diff.patch b/tests/integration/codemod/canonical/mark_internal_to_module/test_codegen/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/mark_internal_to_module/test_codegen/expected_diff.patch rename to tests/integration/codemod/canonical/mark_internal_to_module/test_codegen/expected_diff.patch diff --git a/tests/codemod/canonical/mark_internal_to_module/test_vscode/expected_diff.patch b/tests/integration/codemod/canonical/mark_internal_to_module/test_vscode/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/mark_internal_to_module/test_vscode/expected_diff.patch rename to tests/integration/codemod/canonical/mark_internal_to_module/test_vscode/expected_diff.patch diff --git a/tests/codemod/canonical/mark_is_boolean/test_nest/expected_diff.patch b/tests/integration/codemod/canonical/mark_is_boolean/test_nest/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/mark_is_boolean/test_nest/expected_diff.patch rename to tests/integration/codemod/canonical/mark_is_boolean/test_nest/expected_diff.patch diff --git a/tests/codemod/canonical/mark_is_boolean/test_vscode/expected_diff.patch b/tests/integration/codemod/canonical/mark_is_boolean/test_vscode/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/mark_is_boolean/test_vscode/expected_diff.patch rename to tests/integration/codemod/canonical/mark_is_boolean/test_vscode/expected_diff.patch diff --git a/tests/codemod/canonical/migrate_class_attributes/test_plone/expected_diff.patch b/tests/integration/codemod/canonical/migrate_class_attributes/test_plone/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/migrate_class_attributes/test_plone/expected_diff.patch rename to tests/integration/codemod/canonical/migrate_class_attributes/test_plone/expected_diff.patch diff --git a/tests/codemod/canonical/move_enums_codemod/test_codegen/expected_diff.patch b/tests/integration/codemod/canonical/move_enums_codemod/test_codegen/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/move_enums_codemod/test_codegen/expected_diff.patch rename to tests/integration/codemod/canonical/move_enums_codemod/test_codegen/expected_diff.patch diff --git a/tests/codemod/canonical/move_enums_codemod/test_hass/expected_diff.patch b/tests/integration/codemod/canonical/move_enums_codemod/test_hass/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/move_enums_codemod/test_hass/expected_diff.patch rename to tests/integration/codemod/canonical/move_enums_codemod/test_hass/expected_diff.patch diff --git a/tests/codemod/canonical/move_functions_to_new_file/test_pylsp/expected_diff.patch.skip b/tests/integration/codemod/canonical/move_functions_to_new_file/test_pylsp/expected_diff.patch.skip similarity index 100% rename from tests/codemod/canonical/move_functions_to_new_file/test_pylsp/expected_diff.patch.skip rename to tests/integration/codemod/canonical/move_functions_to_new_file/test_pylsp/expected_diff.patch.skip diff --git a/tests/codemod/canonical/openapi_add_response_none/test_indra/expected_diff.patch.skip b/tests/integration/codemod/canonical/openapi_add_response_none/test_indra/expected_diff.patch.skip similarity index 100% rename from tests/codemod/canonical/openapi_add_response_none/test_indra/expected_diff.patch.skip rename to tests/integration/codemod/canonical/openapi_add_response_none/test_indra/expected_diff.patch.skip diff --git a/tests/codemod/canonical/openapi_no_reference_request/test_codegen/expected_diff.patch b/tests/integration/codemod/canonical/openapi_no_reference_request/test_codegen/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/openapi_no_reference_request/test_codegen/expected_diff.patch rename to tests/integration/codemod/canonical/openapi_no_reference_request/test_codegen/expected_diff.patch diff --git a/tests/codemod/canonical/pascal_case_symbols/test_nest/expected_diff.patch b/tests/integration/codemod/canonical/pascal_case_symbols/test_nest/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/pascal_case_symbols/test_nest/expected_diff.patch rename to tests/integration/codemod/canonical/pascal_case_symbols/test_nest/expected_diff.patch diff --git a/tests/codemod/canonical/pascal_case_symbols/test_vscode/expected_diff.patch b/tests/integration/codemod/canonical/pascal_case_symbols/test_vscode/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/pascal_case_symbols/test_vscode/expected_diff.patch rename to tests/integration/codemod/canonical/pascal_case_symbols/test_vscode/expected_diff.patch diff --git a/tests/codemod/canonical/pivot_return_types/test_hass/expected_diff.patch b/tests/integration/codemod/canonical/pivot_return_types/test_hass/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/pivot_return_types/test_hass/expected_diff.patch rename to tests/integration/codemod/canonical/pivot_return_types/test_hass/expected_diff.patch diff --git a/tests/codemod/canonical/pivot_return_types/test_pylsp/expected_diff.patch b/tests/integration/codemod/canonical/pivot_return_types/test_pylsp/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/pivot_return_types/test_pylsp/expected_diff.patch rename to tests/integration/codemod/canonical/pivot_return_types/test_pylsp/expected_diff.patch diff --git a/tests/codemod/canonical/refactor_react_components_into_separate_files/test_codegen_frontend/expected_diff.patch b/tests/integration/codemod/canonical/refactor_react_components_into_separate_files/test_codegen_frontend/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/refactor_react_components_into_separate_files/test_codegen_frontend/expected_diff.patch rename to tests/integration/codemod/canonical/refactor_react_components_into_separate_files/test_codegen_frontend/expected_diff.patch diff --git a/tests/codemod/canonical/remove_indirect_imports/test_plone/expected_diff.patch b/tests/integration/codemod/canonical/remove_indirect_imports/test_plone/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/remove_indirect_imports/test_plone/expected_diff.patch rename to tests/integration/codemod/canonical/remove_indirect_imports/test_plone/expected_diff.patch diff --git a/tests/codemod/canonical/rename_function_parameters/test_plone/expected_diff.patch b/tests/integration/codemod/canonical/rename_function_parameters/test_plone/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/rename_function_parameters/test_plone/expected_diff.patch rename to tests/integration/codemod/canonical/rename_function_parameters/test_plone/expected_diff.patch diff --git a/tests/codemod/canonical/rename_local_variables/test_pylsp/expected_diff.patch b/tests/integration/codemod/canonical/rename_local_variables/test_pylsp/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/rename_local_variables/test_pylsp/expected_diff.patch rename to tests/integration/codemod/canonical/rename_local_variables/test_pylsp/expected_diff.patch diff --git a/tests/codemod/canonical/replace_prop_values/test_remix_run_examples/expected_diff.patch b/tests/integration/codemod/canonical/replace_prop_values/test_remix_run_examples/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/replace_prop_values/test_remix_run_examples/expected_diff.patch rename to tests/integration/codemod/canonical/replace_prop_values/test_remix_run_examples/expected_diff.patch diff --git a/tests/codemod/canonical/return_none_type_annotation/test_hass/expected_diff.patch b/tests/integration/codemod/canonical/return_none_type_annotation/test_hass/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/return_none_type_annotation/test_hass/expected_diff.patch rename to tests/integration/codemod/canonical/return_none_type_annotation/test_hass/expected_diff.patch diff --git a/tests/codemod/canonical/return_none_type_annotation/test_redash/expected_diff.patch b/tests/integration/codemod/canonical/return_none_type_annotation/test_redash/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/return_none_type_annotation/test_redash/expected_diff.patch rename to tests/integration/codemod/canonical/return_none_type_annotation/test_redash/expected_diff.patch diff --git a/tests/codemod/canonical/split_decorators/test_redash/expected_diff.patch b/tests/integration/codemod/canonical/split_decorators/test_redash/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/split_decorators/test_redash/expected_diff.patch rename to tests/integration/codemod/canonical/split_decorators/test_redash/expected_diff.patch diff --git a/tests/codemod/canonical/split_file/test_sqlglot/expected_diff.patch b/tests/integration/codemod/canonical/split_file/test_sqlglot/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/split_file/test_sqlglot/expected_diff.patch rename to tests/integration/codemod/canonical/split_file/test_sqlglot/expected_diff.patch diff --git a/tests/codemod/canonical/split_file_and_rename_symbols/test_redash/expected_diff.patch b/tests/integration/codemod/canonical/split_file_and_rename_symbols/test_redash/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/split_file_and_rename_symbols/test_redash/expected_diff.patch rename to tests/integration/codemod/canonical/split_file_and_rename_symbols/test_redash/expected_diff.patch diff --git a/tests/codemod/canonical/split_large_files/test_vite/expected_diff.patch.skip b/tests/integration/codemod/canonical/split_large_files/test_vite/expected_diff.patch.skip similarity index 100% rename from tests/codemod/canonical/split_large_files/test_vite/expected_diff.patch.skip rename to tests/integration/codemod/canonical/split_large_files/test_vite/expected_diff.patch.skip diff --git a/tests/codemod/canonical/sqlalchemy_mapped_types/test_redash/expected_diff.patch b/tests/integration/codemod/canonical/sqlalchemy_mapped_types/test_redash/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/sqlalchemy_mapped_types/test_redash/expected_diff.patch rename to tests/integration/codemod/canonical/sqlalchemy_mapped_types/test_redash/expected_diff.patch diff --git a/tests/codemod/canonical/swap_call_site_imports/test_redash/expected_diff.patch b/tests/integration/codemod/canonical/swap_call_site_imports/test_redash/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/swap_call_site_imports/test_redash/expected_diff.patch rename to tests/integration/codemod/canonical/swap_call_site_imports/test_redash/expected_diff.patch diff --git a/tests/codemod/canonical/swap_class_attribute_usages/test_graphrag/expected_diff.patch b/tests/integration/codemod/canonical/swap_class_attribute_usages/test_graphrag/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/swap_class_attribute_usages/test_graphrag/expected_diff.patch rename to tests/integration/codemod/canonical/swap_class_attribute_usages/test_graphrag/expected_diff.patch diff --git a/tests/codemod/canonical/update_optional_type_annotations/test_codegen/expected_diff.patch b/tests/integration/codemod/canonical/update_optional_type_annotations/test_codegen/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/update_optional_type_annotations/test_codegen/expected_diff.patch rename to tests/integration/codemod/canonical/update_optional_type_annotations/test_codegen/expected_diff.patch diff --git a/tests/codemod/canonical/update_optional_type_annotations/test_transformers/expected_diff.patch b/tests/integration/codemod/canonical/update_optional_type_annotations/test_transformers/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/update_optional_type_annotations/test_transformers/expected_diff.patch rename to tests/integration/codemod/canonical/update_optional_type_annotations/test_transformers/expected_diff.patch diff --git a/tests/codemod/canonical/update_union_types/test_fastapi/expected_diff.patch b/tests/integration/codemod/canonical/update_union_types/test_fastapi/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/update_union_types/test_fastapi/expected_diff.patch rename to tests/integration/codemod/canonical/update_union_types/test_fastapi/expected_diff.patch diff --git a/tests/codemod/canonical/use_named_kwargs/test_pylsp/expected_diff.patch b/tests/integration/codemod/canonical/use_named_kwargs/test_pylsp/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/use_named_kwargs/test_pylsp/expected_diff.patch rename to tests/integration/codemod/canonical/use_named_kwargs/test_pylsp/expected_diff.patch diff --git a/tests/codemod/canonical/use_named_kwargs/test_transformers/expected_diff.patch b/tests/integration/codemod/canonical/use_named_kwargs/test_transformers/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/use_named_kwargs/test_transformers/expected_diff.patch rename to tests/integration/codemod/canonical/use_named_kwargs/test_transformers/expected_diff.patch diff --git a/tests/codemod/canonical/wrap_with_component/test_virtual_coffee/expected_diff.patch b/tests/integration/codemod/canonical/wrap_with_component/test_virtual_coffee/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/wrap_with_component/test_virtual_coffee/expected_diff.patch rename to tests/integration/codemod/canonical/wrap_with_component/test_virtual_coffee/expected_diff.patch diff --git a/tests/codemod/canonical/wrap_with_statement/test_hass/expected_diff.patch b/tests/integration/codemod/canonical/wrap_with_statement/test_hass/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/wrap_with_statement/test_hass/expected_diff.patch rename to tests/integration/codemod/canonical/wrap_with_statement/test_hass/expected_diff.patch diff --git a/tests/codemod/canonical/wrap_with_statement/test_redash/expected_diff.patch b/tests/integration/codemod/canonical/wrap_with_statement/test_redash/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/wrap_with_statement/test_redash/expected_diff.patch rename to tests/integration/codemod/canonical/wrap_with_statement/test_redash/expected_diff.patch diff --git a/tests/codemod/canonical/wrap_with_use_callback/test_remix_run_examples/expected_diff.patch b/tests/integration/codemod/canonical/wrap_with_use_callback/test_remix_run_examples/expected_diff.patch similarity index 100% rename from tests/codemod/canonical/wrap_with_use_callback/test_remix_run_examples/expected_diff.patch rename to tests/integration/codemod/canonical/wrap_with_use_callback/test_remix_run_examples/expected_diff.patch diff --git a/tests/codemod/conftest.py b/tests/integration/codemod/conftest.py similarity index 100% rename from tests/codemod/conftest.py rename to tests/integration/codemod/conftest.py diff --git a/tests/codemod/repos/extra/1.json b/tests/integration/codemod/repos/extra/1.json similarity index 100% rename from tests/codemod/repos/extra/1.json rename to tests/integration/codemod/repos/extra/1.json diff --git a/tests/codemod/repos/extra/2.json b/tests/integration/codemod/repos/extra/2.json similarity index 100% rename from tests/codemod/repos/extra/2.json rename to tests/integration/codemod/repos/extra/2.json diff --git a/tests/codemod/repos/extra/3.json b/tests/integration/codemod/repos/extra/3.json similarity index 100% rename from tests/codemod/repos/extra/3.json rename to tests/integration/codemod/repos/extra/3.json diff --git a/tests/codemod/repos/extra/4.json b/tests/integration/codemod/repos/extra/4.json similarity index 100% rename from tests/codemod/repos/extra/4.json rename to tests/integration/codemod/repos/extra/4.json diff --git a/tests/codemod/repos/extra/5.json b/tests/integration/codemod/repos/extra/5.json similarity index 100% rename from tests/codemod/repos/extra/5.json rename to tests/integration/codemod/repos/extra/5.json diff --git a/tests/codemod/repos/extra/6.json b/tests/integration/codemod/repos/extra/6.json similarity index 100% rename from tests/codemod/repos/extra/6.json rename to tests/integration/codemod/repos/extra/6.json diff --git a/tests/codemod/repos/extra/7.json b/tests/integration/codemod/repos/extra/7.json similarity index 100% rename from tests/codemod/repos/extra/7.json rename to tests/integration/codemod/repos/extra/7.json diff --git a/tests/codemod/repos/extra/8.json b/tests/integration/codemod/repos/extra/8.json similarity index 100% rename from tests/codemod/repos/extra/8.json rename to tests/integration/codemod/repos/extra/8.json diff --git a/tests/codemod/repos/open_source/airflow.json b/tests/integration/codemod/repos/open_source/airflow.json similarity index 100% rename from tests/codemod/repos/open_source/airflow.json rename to tests/integration/codemod/repos/open_source/airflow.json diff --git a/tests/codemod/repos/open_source/codegen.json b/tests/integration/codemod/repos/open_source/codegen.json similarity index 100% rename from tests/codemod/repos/open_source/codegen.json rename to tests/integration/codemod/repos/open_source/codegen.json diff --git a/tests/codemod/repos/open_source/codegen_frontend.json b/tests/integration/codemod/repos/open_source/codegen_frontend.json similarity index 100% rename from tests/codemod/repos/open_source/codegen_frontend.json rename to tests/integration/codemod/repos/open_source/codegen_frontend.json diff --git a/tests/codemod/repos/open_source/codegen_tests.json b/tests/integration/codemod/repos/open_source/codegen_tests.json similarity index 100% rename from tests/codemod/repos/open_source/codegen_tests.json rename to tests/integration/codemod/repos/open_source/codegen_tests.json diff --git a/tests/codemod/repos/open_source/cypress.json b/tests/integration/codemod/repos/open_source/cypress.json similarity index 100% rename from tests/codemod/repos/open_source/cypress.json rename to tests/integration/codemod/repos/open_source/cypress.json diff --git a/tests/codemod/repos/open_source/deno_rest.json b/tests/integration/codemod/repos/open_source/deno_rest.json similarity index 100% rename from tests/codemod/repos/open_source/deno_rest.json rename to tests/integration/codemod/repos/open_source/deno_rest.json diff --git a/tests/codemod/repos/open_source/django.json b/tests/integration/codemod/repos/open_source/django.json similarity index 100% rename from tests/codemod/repos/open_source/django.json rename to tests/integration/codemod/repos/open_source/django.json diff --git a/tests/codemod/repos/open_source/fastapi.json b/tests/integration/codemod/repos/open_source/fastapi.json similarity index 100% rename from tests/codemod/repos/open_source/fastapi.json rename to tests/integration/codemod/repos/open_source/fastapi.json diff --git a/tests/codemod/repos/open_source/flask-bones.json b/tests/integration/codemod/repos/open_source/flask-bones.json similarity index 100% rename from tests/codemod/repos/open_source/flask-bones.json rename to tests/integration/codemod/repos/open_source/flask-bones.json diff --git a/tests/codemod/repos/open_source/flask.json b/tests/integration/codemod/repos/open_source/flask.json similarity index 100% rename from tests/codemod/repos/open_source/flask.json rename to tests/integration/codemod/repos/open_source/flask.json diff --git a/tests/codemod/repos/open_source/graphrag.json b/tests/integration/codemod/repos/open_source/graphrag.json similarity index 100% rename from tests/codemod/repos/open_source/graphrag.json rename to tests/integration/codemod/repos/open_source/graphrag.json diff --git a/tests/codemod/repos/open_source/hass.json b/tests/integration/codemod/repos/open_source/hass.json similarity index 100% rename from tests/codemod/repos/open_source/hass.json rename to tests/integration/codemod/repos/open_source/hass.json diff --git a/tests/codemod/repos/open_source/indico.json b/tests/integration/codemod/repos/open_source/indico.json similarity index 100% rename from tests/codemod/repos/open_source/indico.json rename to tests/integration/codemod/repos/open_source/indico.json diff --git a/tests/codemod/repos/open_source/indra.json b/tests/integration/codemod/repos/open_source/indra.json similarity index 100% rename from tests/codemod/repos/open_source/indra.json rename to tests/integration/codemod/repos/open_source/indra.json diff --git a/tests/codemod/repos/open_source/jchat.json b/tests/integration/codemod/repos/open_source/jchat.json similarity index 100% rename from tests/codemod/repos/open_source/jchat.json rename to tests/integration/codemod/repos/open_source/jchat.json diff --git a/tests/codemod/repos/open_source/mypy.json b/tests/integration/codemod/repos/open_source/mypy.json similarity index 100% rename from tests/codemod/repos/open_source/mypy.json rename to tests/integration/codemod/repos/open_source/mypy.json diff --git a/tests/codemod/repos/open_source/nest.json b/tests/integration/codemod/repos/open_source/nest.json similarity index 100% rename from tests/codemod/repos/open_source/nest.json rename to tests/integration/codemod/repos/open_source/nest.json diff --git a/tests/codemod/repos/open_source/papermark.json b/tests/integration/codemod/repos/open_source/papermark.json similarity index 100% rename from tests/codemod/repos/open_source/papermark.json rename to tests/integration/codemod/repos/open_source/papermark.json diff --git a/tests/codemod/repos/open_source/plone.json b/tests/integration/codemod/repos/open_source/plone.json similarity index 100% rename from tests/codemod/repos/open_source/plone.json rename to tests/integration/codemod/repos/open_source/plone.json diff --git a/tests/codemod/repos/open_source/pylsp.json b/tests/integration/codemod/repos/open_source/pylsp.json similarity index 100% rename from tests/codemod/repos/open_source/pylsp.json rename to tests/integration/codemod/repos/open_source/pylsp.json diff --git a/tests/codemod/repos/open_source/redash.json b/tests/integration/codemod/repos/open_source/redash.json similarity index 100% rename from tests/codemod/repos/open_source/redash.json rename to tests/integration/codemod/repos/open_source/redash.json diff --git a/tests/codemod/repos/open_source/remix_run_examples.json b/tests/integration/codemod/repos/open_source/remix_run_examples.json similarity index 100% rename from tests/codemod/repos/open_source/remix_run_examples.json rename to tests/integration/codemod/repos/open_source/remix_run_examples.json diff --git a/tests/codemod/repos/open_source/requests-oauthlib.json b/tests/integration/codemod/repos/open_source/requests-oauthlib.json similarity index 100% rename from tests/codemod/repos/open_source/requests-oauthlib.json rename to tests/integration/codemod/repos/open_source/requests-oauthlib.json diff --git a/tests/codemod/repos/open_source/sqlglot.json b/tests/integration/codemod/repos/open_source/sqlglot.json similarity index 100% rename from tests/codemod/repos/open_source/sqlglot.json rename to tests/integration/codemod/repos/open_source/sqlglot.json diff --git a/tests/codemod/repos/open_source/suite.json b/tests/integration/codemod/repos/open_source/suite.json similarity index 100% rename from tests/codemod/repos/open_source/suite.json rename to tests/integration/codemod/repos/open_source/suite.json diff --git a/tests/codemod/repos/open_source/transformers.json b/tests/integration/codemod/repos/open_source/transformers.json similarity index 100% rename from tests/codemod/repos/open_source/transformers.json rename to tests/integration/codemod/repos/open_source/transformers.json diff --git a/tests/codemod/repos/open_source/typeshed.json b/tests/integration/codemod/repos/open_source/typeshed.json similarity index 100% rename from tests/codemod/repos/open_source/typeshed.json rename to tests/integration/codemod/repos/open_source/typeshed.json diff --git a/tests/codemod/repos/open_source/virtual_coffee.json b/tests/integration/codemod/repos/open_source/virtual_coffee.json similarity index 100% rename from tests/codemod/repos/open_source/virtual_coffee.json rename to tests/integration/codemod/repos/open_source/virtual_coffee.json diff --git a/tests/codemod/repos/open_source/vite.json b/tests/integration/codemod/repos/open_source/vite.json similarity index 100% rename from tests/codemod/repos/open_source/vite.json rename to tests/integration/codemod/repos/open_source/vite.json diff --git a/tests/codemod/repos/open_source/vscode.json b/tests/integration/codemod/repos/open_source/vscode.json similarity index 100% rename from tests/codemod/repos/open_source/vscode.json rename to tests/integration/codemod/repos/open_source/vscode.json diff --git a/tests/codemod/repos/repos.json b/tests/integration/codemod/repos/repos.json similarity index 100% rename from tests/codemod/repos/repos.json rename to tests/integration/codemod/repos/repos.json diff --git a/tests/codemod/test_codemods.py b/tests/integration/codemod/test_codemods.py similarity index 100% rename from tests/codemod/test_codemods.py rename to tests/integration/codemod/test_codemods.py diff --git a/tests/codemod/test_diffs.py b/tests/integration/codemod/test_diffs.py similarity index 100% rename from tests/codemod/test_diffs.py rename to tests/integration/codemod/test_diffs.py diff --git a/tests/codemod/test_parse.py b/tests/integration/codemod/test_parse.py similarity index 100% rename from tests/codemod/test_parse.py rename to tests/integration/codemod/test_parse.py diff --git a/tests/codemod/test_verified_codemods.py b/tests/integration/codemod/test_verified_codemods.py similarity index 100% rename from tests/codemod/test_verified_codemods.py rename to tests/integration/codemod/test_verified_codemods.py diff --git a/tests/verified_codemods/codemod_data/MTIwNTFlOT.json b/tests/integration/verified_codemods/codemod_data/MTIwNTFlOT.json similarity index 100% rename from tests/verified_codemods/codemod_data/MTIwNTFlOT.json rename to tests/integration/verified_codemods/codemod_data/MTIwNTFlOT.json diff --git a/tests/verified_codemods/codemod_data/MmI0ZGE5ND.json b/tests/integration/verified_codemods/codemod_data/MmI0ZGE5ND.json similarity index 100% rename from tests/verified_codemods/codemod_data/MmI0ZGE5ND.json rename to tests/integration/verified_codemods/codemod_data/MmI0ZGE5ND.json diff --git a/tests/verified_codemods/codemod_data/MmY3NGQ2Mm.json b/tests/integration/verified_codemods/codemod_data/MmY3NGQ2Mm.json similarity index 100% rename from tests/verified_codemods/codemod_data/MmY3NGQ2Mm.json rename to tests/integration/verified_codemods/codemod_data/MmY3NGQ2Mm.json diff --git a/tests/verified_codemods/codemod_data/MzEzYzkzOG.json b/tests/integration/verified_codemods/codemod_data/MzEzYzkzOG.json similarity index 100% rename from tests/verified_codemods/codemod_data/MzEzYzkzOG.json rename to tests/integration/verified_codemods/codemod_data/MzEzYzkzOG.json diff --git a/tests/verified_codemods/codemod_data/N2IyYzIxZW.json b/tests/integration/verified_codemods/codemod_data/N2IyYzIxZW.json similarity index 100% rename from tests/verified_codemods/codemod_data/N2IyYzIxZW.json rename to tests/integration/verified_codemods/codemod_data/N2IyYzIxZW.json diff --git a/tests/verified_codemods/codemod_data/N2Q3MTc5Yz.json b/tests/integration/verified_codemods/codemod_data/N2Q3MTc5Yz.json similarity index 100% rename from tests/verified_codemods/codemod_data/N2Q3MTc5Yz.json rename to tests/integration/verified_codemods/codemod_data/N2Q3MTc5Yz.json diff --git a/tests/verified_codemods/codemod_data/NDYyMWMxZD.json b/tests/integration/verified_codemods/codemod_data/NDYyMWMxZD.json similarity index 100% rename from tests/verified_codemods/codemod_data/NDYyMWMxZD.json rename to tests/integration/verified_codemods/codemod_data/NDYyMWMxZD.json diff --git a/tests/verified_codemods/codemod_data/NGQwMTk4Zj.json b/tests/integration/verified_codemods/codemod_data/NGQwMTk4Zj.json similarity index 100% rename from tests/verified_codemods/codemod_data/NGQwMTk4Zj.json rename to tests/integration/verified_codemods/codemod_data/NGQwMTk4Zj.json diff --git a/tests/verified_codemods/codemod_data/NTEwNTRiOG.json b/tests/integration/verified_codemods/codemod_data/NTEwNTRiOG.json similarity index 100% rename from tests/verified_codemods/codemod_data/NTEwNTRiOG.json rename to tests/integration/verified_codemods/codemod_data/NTEwNTRiOG.json diff --git a/tests/verified_codemods/codemod_data/NTI4M2YxYj.json b/tests/integration/verified_codemods/codemod_data/NTI4M2YxYj.json similarity index 100% rename from tests/verified_codemods/codemod_data/NTI4M2YxYj.json rename to tests/integration/verified_codemods/codemod_data/NTI4M2YxYj.json diff --git a/tests/verified_codemods/codemod_data/ODlhYTFlNT.json b/tests/integration/verified_codemods/codemod_data/ODlhYTFlNT.json similarity index 100% rename from tests/verified_codemods/codemod_data/ODlhYTFlNT.json rename to tests/integration/verified_codemods/codemod_data/ODlhYTFlNT.json diff --git a/tests/verified_codemods/codemod_data/OGRmZDEzZj.json b/tests/integration/verified_codemods/codemod_data/OGRmZDEzZj.json similarity index 100% rename from tests/verified_codemods/codemod_data/OGRmZDEzZj.json rename to tests/integration/verified_codemods/codemod_data/OGRmZDEzZj.json diff --git a/tests/verified_codemods/codemod_data/OTNjMzc1NW.json b/tests/integration/verified_codemods/codemod_data/OTNjMzc1NW.json similarity index 100% rename from tests/verified_codemods/codemod_data/OTNjMzc1NW.json rename to tests/integration/verified_codemods/codemod_data/OTNjMzc1NW.json diff --git a/tests/verified_codemods/codemod_data/YTY2NWE0NT.json b/tests/integration/verified_codemods/codemod_data/YTY2NWE0NT.json similarity index 100% rename from tests/verified_codemods/codemod_data/YTY2NWE0NT.json rename to tests/integration/verified_codemods/codemod_data/YTY2NWE0NT.json diff --git a/tests/verified_codemods/codemod_data/YWU0ZGVmMW.json b/tests/integration/verified_codemods/codemod_data/YWU0ZGVmMW.json similarity index 100% rename from tests/verified_codemods/codemod_data/YWU0ZGVmMW.json rename to tests/integration/verified_codemods/codemod_data/YWU0ZGVmMW.json diff --git a/tests/verified_codemods/codemod_data/YjRiYmU0ND.json b/tests/integration/verified_codemods/codemod_data/YjRiYmU0ND.json similarity index 100% rename from tests/verified_codemods/codemod_data/YjRiYmU0ND.json rename to tests/integration/verified_codemods/codemod_data/YjRiYmU0ND.json diff --git a/tests/verified_codemods/codemod_data/YmUxNzIyYj.json b/tests/integration/verified_codemods/codemod_data/YmUxNzIyYj.json similarity index 100% rename from tests/verified_codemods/codemod_data/YmUxNzIyYj.json rename to tests/integration/verified_codemods/codemod_data/YmUxNzIyYj.json diff --git a/tests/verified_codemods/codemod_data/ZDFjNzhjOW.json b/tests/integration/verified_codemods/codemod_data/ZDFjNzhjOW.json similarity index 100% rename from tests/verified_codemods/codemod_data/ZDFjNzhjOW.json rename to tests/integration/verified_codemods/codemod_data/ZDFjNzhjOW.json diff --git a/tests/verified_codemods/codemod_data/ZGYxNTZlOD.json b/tests/integration/verified_codemods/codemod_data/ZGYxNTZlOD.json similarity index 100% rename from tests/verified_codemods/codemod_data/ZGYxNTZlOD.json rename to tests/integration/verified_codemods/codemod_data/ZGYxNTZlOD.json diff --git a/tests/verified_codemods/codemod_data/ZjUzZjJmYj.json b/tests/integration/verified_codemods/codemod_data/ZjUzZjJmYj.json similarity index 100% rename from tests/verified_codemods/codemod_data/ZjUzZjJmYj.json rename to tests/integration/verified_codemods/codemod_data/ZjUzZjJmYj.json diff --git a/tests/verified_codemods/codemod_data/ZmQwZjdlNT.json b/tests/integration/verified_codemods/codemod_data/ZmQwZjdlNT.json similarity index 100% rename from tests/verified_codemods/codemod_data/ZmQwZjdlNT.json rename to tests/integration/verified_codemods/codemod_data/ZmQwZjdlNT.json diff --git a/tests/shared/README.md b/tests/shared/README.md new file mode 100644 index 000000000..171f05cf8 --- /dev/null +++ b/tests/shared/README.md @@ -0,0 +1,4 @@ +# Tests/shared + +### What kind of things should go in here? +Testing utilities like mocks, fixtures, test data that are used across multiple tests. diff --git a/tests/unit/codegen/sdk/output/snapshots/test_ast/test_ast_basic/ast.json b/tests/unit/codegen/sdk/output/snapshots/test_ast/test_ast_basic/ast.json index 27e102535..1d7784baf 100644 --- a/tests/unit/codegen/sdk/output/snapshots/test_ast/test_ast_basic/ast.json +++ b/tests/unit/codegen/sdk/output/snapshots/test_ast/test_ast_basic/ast.json @@ -1,327 +1,327 @@ { - "codegen_sdk_type": "PyClass", - "span": { - "range": { - "start_byte": 1, - "end_byte": 48, - "start_point": { - "row": 1, - "column": 0 - }, - "end_point": { - "row": 3, - "column": 18 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "class_definition", - "children": [ - [ - "get_name()", - { - "codegen_sdk_type": "Name", - "span": { - "range": { - "start_byte": 7, - "end_byte": 10, - "start_point": { - "row": 1, - "column": 6 - }, - "end_point": { - "row": 1, - "column": 9 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "identifier", - "children": [] - } - ], - [ - "methods", - { - "codegen_sdk_type": "PyCodeBlock", - "span": { - "range": { - "start_byte": 16, - "end_byte": 48, - "start_point": { - "row": 2, - "column": 4 - }, - "end_point": { - "row": 3, - "column": 18 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "block", - "children": [ - [ - "statements", - { - "codegen_sdk_type": "MultiLineCollection", - "span": { - "range": { - "start_byte": 16, - "end_byte": 48, - "start_point": { - "row": 2, - "column": 4 - }, - "end_point": { - "row": 3, - "column": 18 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "block", - "children": [ - [ - null, - { - "codegen_sdk_type": "SymbolStatement", - "span": { - "range": { - "start_byte": 16, - "end_byte": 48, - "start_point": { - "row": 2, - "column": 4 - }, - "end_point": { - "row": 3, - "column": 18 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "function_definition", - "children": [ - [ - null, - { - "codegen_sdk_type": "Name", - "span": { - "range": { - "start_byte": 20, - "end_byte": 23, - "start_point": { - "row": 2, - "column": 8 - }, - "end_point": { - "row": 2, - "column": 11 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "identifier", - "children": [] - } - ], - [ - null, - { - "codegen_sdk_type": "Collection", - "span": { - "range": { - "start_byte": 23, - "end_byte": 28, - "start_point": { - "row": 2, - "column": 11 - }, - "end_point": { - "row": 2, - "column": 16 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "parameters", - "children": [ - [ - null, - { - "codegen_sdk_type": "PyParameter", - "span": { - "range": { - "start_byte": 24, - "end_byte": 27, - "start_point": { - "row": 2, - "column": 12 - }, - "end_point": { - "row": 2, - "column": 15 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "identifier", - "children": [] - } - ] - ] - } - ], - [ - null, - { - "codegen_sdk_type": "PyCodeBlock", - "span": { - "range": { - "start_byte": 38, - "end_byte": 48, - "start_point": { - "row": 3, - "column": 8 - }, - "end_point": { - "row": 3, - "column": 18 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "block", - "children": [ - [ - "statements", - { - "codegen_sdk_type": "MultiLineCollection", - "span": { - "range": { - "start_byte": 38, - "end_byte": 48, - "start_point": { - "row": 3, - "column": 8 - }, - "end_point": { - "row": 3, - "column": 18 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "block", - "children": [ - [ - null, - { - "codegen_sdk_type": "ReturnStatement", - "span": { - "range": { - "start_byte": 38, - "end_byte": 48, - "start_point": { - "row": 3, - "column": 8 - }, - "end_point": { - "row": 3, - "column": 18 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "return_statement", - "children": [ - [ - "value", - { - "codegen_sdk_type": "Name", - "span": { - "range": { - "start_byte": 45, - "end_byte": 48, - "start_point": { - "row": 3, - "column": 15 - }, - "end_point": { - "row": 3, - "column": 18 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "identifier", - "children": [] - } - ] - ] - } - ] - ] - } - ] - ] - } - ] - ] - } - ] - ] - } - ] - ] - } - ], - [ - null, - { - "codegen_sdk_type": "Name", - "span": { - "range": { - "start_byte": 20, - "end_byte": 23, - "start_point": { - "row": 2, - "column": 8 - }, - "end_point": { - "row": 2, - "column": 11 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "identifier", - "children": [] - } - ], - [ - null, - { - "codegen_sdk_type": "Name", - "span": { - "range": { - "start_byte": 24, - "end_byte": 27, - "start_point": { - "row": 2, - "column": 12 - }, - "end_point": { - "row": 2, - "column": 15 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "identifier", - "children": [] - } - ] - ] + "codegen_sdk_type": "PyClass", + "span": { + "range": { + "start_byte": 1, + "end_byte": 48, + "start_point": { + "row": 1, + "column": 0 + }, + "end_point": { + "row": 3, + "column": 18 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "class_definition", + "children": [ + [ + "get_name()", + { + "codegen_sdk_type": "Name", + "span": { + "range": { + "start_byte": 7, + "end_byte": 10, + "start_point": { + "row": 1, + "column": 6 + }, + "end_point": { + "row": 1, + "column": 9 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "identifier", + "children": [] + } + ], + [ + "methods", + { + "codegen_sdk_type": "PyCodeBlock", + "span": { + "range": { + "start_byte": 16, + "end_byte": 48, + "start_point": { + "row": 2, + "column": 4 + }, + "end_point": { + "row": 3, + "column": 18 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "block", + "children": [ + [ + "statements", + { + "codegen_sdk_type": "MultiLineCollection", + "span": { + "range": { + "start_byte": 16, + "end_byte": 48, + "start_point": { + "row": 2, + "column": 4 + }, + "end_point": { + "row": 3, + "column": 18 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "block", + "children": [ + [ + null, + { + "codegen_sdk_type": "SymbolStatement", + "span": { + "range": { + "start_byte": 16, + "end_byte": 48, + "start_point": { + "row": 2, + "column": 4 + }, + "end_point": { + "row": 3, + "column": 18 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "function_definition", + "children": [ + [ + null, + { + "codegen_sdk_type": "Name", + "span": { + "range": { + "start_byte": 20, + "end_byte": 23, + "start_point": { + "row": 2, + "column": 8 + }, + "end_point": { + "row": 2, + "column": 11 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "identifier", + "children": [] + } + ], + [ + null, + { + "codegen_sdk_type": "Collection", + "span": { + "range": { + "start_byte": 23, + "end_byte": 28, + "start_point": { + "row": 2, + "column": 11 + }, + "end_point": { + "row": 2, + "column": 16 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "parameters", + "children": [ + [ + null, + { + "codegen_sdk_type": "PyParameter", + "span": { + "range": { + "start_byte": 24, + "end_byte": 27, + "start_point": { + "row": 2, + "column": 12 + }, + "end_point": { + "row": 2, + "column": 15 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "identifier", + "children": [] + } + ] + ] + } + ], + [ + null, + { + "codegen_sdk_type": "PyCodeBlock", + "span": { + "range": { + "start_byte": 38, + "end_byte": 48, + "start_point": { + "row": 3, + "column": 8 + }, + "end_point": { + "row": 3, + "column": 18 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "block", + "children": [ + [ + "statements", + { + "codegen_sdk_type": "MultiLineCollection", + "span": { + "range": { + "start_byte": 38, + "end_byte": 48, + "start_point": { + "row": 3, + "column": 8 + }, + "end_point": { + "row": 3, + "column": 18 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "block", + "children": [ + [ + null, + { + "codegen_sdk_type": "ReturnStatement", + "span": { + "range": { + "start_byte": 38, + "end_byte": 48, + "start_point": { + "row": 3, + "column": 8 + }, + "end_point": { + "row": 3, + "column": 18 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "return_statement", + "children": [ + [ + "value", + { + "codegen_sdk_type": "Name", + "span": { + "range": { + "start_byte": 45, + "end_byte": 48, + "start_point": { + "row": 3, + "column": 15 + }, + "end_point": { + "row": 3, + "column": 18 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "identifier", + "children": [] + } + ] + ] + } + ] + ] + } + ] + ] + } + ] + ] + } + ] + ] + } + ] + ] + } + ], + [ + null, + { + "codegen_sdk_type": "Name", + "span": { + "range": { + "start_byte": 20, + "end_byte": 23, + "start_point": { + "row": 2, + "column": 8 + }, + "end_point": { + "row": 2, + "column": 11 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "identifier", + "children": [] + } + ], + [ + null, + { + "codegen_sdk_type": "Name", + "span": { + "range": { + "start_byte": 24, + "end_byte": 27, + "start_point": { + "row": 2, + "column": 12 + }, + "end_point": { + "row": 2, + "column": 15 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "identifier", + "children": [] + } + ] + ] } diff --git a/tests/unit/codegen/sdk/output/snapshots/test_ast/test_ast_nested/ast-nested.json b/tests/unit/codegen/sdk/output/snapshots/test_ast/test_ast_nested/ast-nested.json index 276f5605f..3079c70e1 100644 --- a/tests/unit/codegen/sdk/output/snapshots/test_ast/test_ast_nested/ast-nested.json +++ b/tests/unit/codegen/sdk/output/snapshots/test_ast/test_ast_nested/ast-nested.json @@ -1,421 +1,421 @@ { - "codegen_sdk_type": "PyClass", - "span": { - "range": { - "start_byte": 1, - "end_byte": 66, - "start_point": { - "row": 1, - "column": 0 - }, - "end_point": { - "row": 4, - "column": 16 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "class_definition", - "children": [ - [ - "get_name()", - { - "codegen_sdk_type": "Name", - "span": { - "range": { - "start_byte": 7, - "end_byte": 10, - "start_point": { - "row": 1, - "column": 6 - }, - "end_point": { - "row": 1, - "column": 9 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "identifier", - "children": [] - } - ], - [ - "methods", - { - "codegen_sdk_type": "PyCodeBlock", - "span": { - "range": { - "start_byte": 16, - "end_byte": 66, - "start_point": { - "row": 2, - "column": 4 - }, - "end_point": { - "row": 4, - "column": 16 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "block", - "children": [ - [ - "statements", - { - "codegen_sdk_type": "MultiLineCollection", - "span": { - "range": { - "start_byte": 16, - "end_byte": 66, - "start_point": { - "row": 2, - "column": 4 - }, - "end_point": { - "row": 4, - "column": 16 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "block", - "children": [ - [ - null, - { - "codegen_sdk_type": "SymbolStatement", - "span": { - "range": { - "start_byte": 16, - "end_byte": 66, - "start_point": { - "row": 2, - "column": 4 - }, - "end_point": { - "row": 4, - "column": 16 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "class_definition", - "children": [ - [ - null, - { - "codegen_sdk_type": "Name", - "span": { - "range": { - "start_byte": 22, - "end_byte": 25, - "start_point": { - "row": 2, - "column": 10 - }, - "end_point": { - "row": 2, - "column": 13 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "identifier", - "children": [] - } - ], - [ - null, - { - "codegen_sdk_type": "PyCodeBlock", - "span": { - "range": { - "start_byte": 35, - "end_byte": 66, - "start_point": { - "row": 3, - "column": 8 - }, - "end_point": { - "row": 4, - "column": 16 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "block", - "children": [ - [ - "statements", - { - "codegen_sdk_type": "MultiLineCollection", - "span": { - "range": { - "start_byte": 35, - "end_byte": 66, - "start_point": { - "row": 3, - "column": 8 - }, - "end_point": { - "row": 4, - "column": 16 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "block", - "children": [ - [ - null, - { - "codegen_sdk_type": "SymbolStatement", - "span": { - "range": { - "start_byte": 35, - "end_byte": 66, - "start_point": { - "row": 3, - "column": 8 - }, - "end_point": { - "row": 4, - "column": 16 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "function_definition", - "children": [ - [ - null, - { - "codegen_sdk_type": "Name", - "span": { - "range": { - "start_byte": 39, - "end_byte": 42, - "start_point": { - "row": 3, - "column": 12 - }, - "end_point": { - "row": 3, - "column": 15 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "identifier", - "children": [] - } - ], - [ - null, - { - "codegen_sdk_type": "Collection", - "span": { - "range": { - "start_byte": 42, - "end_byte": 48, - "start_point": { - "row": 3, - "column": 15 - }, - "end_point": { - "row": 3, - "column": 21 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "parameters", - "children": [ - [ - null, - { - "codegen_sdk_type": "PyParameter", - "span": { - "range": { - "start_byte": 43, - "end_byte": 47, - "start_point": { - "row": 3, - "column": 16 - }, - "end_point": { - "row": 3, - "column": 20 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "identifier", - "children": [] - } - ] - ] - } - ], - [ - null, - { - "codegen_sdk_type": "PyCodeBlock", - "span": { - "range": { - "start_byte": 62, - "end_byte": 66, - "start_point": { - "row": 4, - "column": 12 - }, - "end_point": { - "row": 4, - "column": 16 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "block", - "children": [ - [ - "statements", - { - "codegen_sdk_type": "MultiLineCollection", - "span": { - "range": { - "start_byte": 62, - "end_byte": 66, - "start_point": { - "row": 4, - "column": 12 - }, - "end_point": { - "row": 4, - "column": 16 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "block", - "children": [ - [ - null, - { - "codegen_sdk_type": "PyPassStatement", - "span": { - "range": { - "start_byte": 62, - "end_byte": 66, - "start_point": { - "row": 4, - "column": 12 - }, - "end_point": { - "row": 4, - "column": 16 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "pass_statement", - "children": [] - } - ] - ] - } - ] - ] - } - ] - ] - } - ] - ] - } - ] - ] - } - ] - ] - } - ] - ] - } - ] - ] - } - ], - [ - null, - { - "codegen_sdk_type": "Name", - "span": { - "range": { - "start_byte": 22, - "end_byte": 25, - "start_point": { - "row": 2, - "column": 10 - }, - "end_point": { - "row": 2, - "column": 13 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "identifier", - "children": [] - } - ], - [ - null, - { - "codegen_sdk_type": "Name", - "span": { - "range": { - "start_byte": 39, - "end_byte": 42, - "start_point": { - "row": 3, - "column": 12 - }, - "end_point": { - "row": 3, - "column": 15 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "identifier", - "children": [] - } - ], - [ - null, - { - "codegen_sdk_type": "Name", - "span": { - "range": { - "start_byte": 43, - "end_byte": 47, - "start_point": { - "row": 3, - "column": 16 - }, - "end_point": { - "row": 3, - "column": 20 - } - }, - "filepath": "test.py" - }, - "tree_sitter_type": "identifier", - "children": [] - } - ] - ] + "codegen_sdk_type": "PyClass", + "span": { + "range": { + "start_byte": 1, + "end_byte": 66, + "start_point": { + "row": 1, + "column": 0 + }, + "end_point": { + "row": 4, + "column": 16 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "class_definition", + "children": [ + [ + "get_name()", + { + "codegen_sdk_type": "Name", + "span": { + "range": { + "start_byte": 7, + "end_byte": 10, + "start_point": { + "row": 1, + "column": 6 + }, + "end_point": { + "row": 1, + "column": 9 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "identifier", + "children": [] + } + ], + [ + "methods", + { + "codegen_sdk_type": "PyCodeBlock", + "span": { + "range": { + "start_byte": 16, + "end_byte": 66, + "start_point": { + "row": 2, + "column": 4 + }, + "end_point": { + "row": 4, + "column": 16 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "block", + "children": [ + [ + "statements", + { + "codegen_sdk_type": "MultiLineCollection", + "span": { + "range": { + "start_byte": 16, + "end_byte": 66, + "start_point": { + "row": 2, + "column": 4 + }, + "end_point": { + "row": 4, + "column": 16 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "block", + "children": [ + [ + null, + { + "codegen_sdk_type": "SymbolStatement", + "span": { + "range": { + "start_byte": 16, + "end_byte": 66, + "start_point": { + "row": 2, + "column": 4 + }, + "end_point": { + "row": 4, + "column": 16 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "class_definition", + "children": [ + [ + null, + { + "codegen_sdk_type": "Name", + "span": { + "range": { + "start_byte": 22, + "end_byte": 25, + "start_point": { + "row": 2, + "column": 10 + }, + "end_point": { + "row": 2, + "column": 13 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "identifier", + "children": [] + } + ], + [ + null, + { + "codegen_sdk_type": "PyCodeBlock", + "span": { + "range": { + "start_byte": 35, + "end_byte": 66, + "start_point": { + "row": 3, + "column": 8 + }, + "end_point": { + "row": 4, + "column": 16 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "block", + "children": [ + [ + "statements", + { + "codegen_sdk_type": "MultiLineCollection", + "span": { + "range": { + "start_byte": 35, + "end_byte": 66, + "start_point": { + "row": 3, + "column": 8 + }, + "end_point": { + "row": 4, + "column": 16 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "block", + "children": [ + [ + null, + { + "codegen_sdk_type": "SymbolStatement", + "span": { + "range": { + "start_byte": 35, + "end_byte": 66, + "start_point": { + "row": 3, + "column": 8 + }, + "end_point": { + "row": 4, + "column": 16 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "function_definition", + "children": [ + [ + null, + { + "codegen_sdk_type": "Name", + "span": { + "range": { + "start_byte": 39, + "end_byte": 42, + "start_point": { + "row": 3, + "column": 12 + }, + "end_point": { + "row": 3, + "column": 15 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "identifier", + "children": [] + } + ], + [ + null, + { + "codegen_sdk_type": "Collection", + "span": { + "range": { + "start_byte": 42, + "end_byte": 48, + "start_point": { + "row": 3, + "column": 15 + }, + "end_point": { + "row": 3, + "column": 21 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "parameters", + "children": [ + [ + null, + { + "codegen_sdk_type": "PyParameter", + "span": { + "range": { + "start_byte": 43, + "end_byte": 47, + "start_point": { + "row": 3, + "column": 16 + }, + "end_point": { + "row": 3, + "column": 20 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "identifier", + "children": [] + } + ] + ] + } + ], + [ + null, + { + "codegen_sdk_type": "PyCodeBlock", + "span": { + "range": { + "start_byte": 62, + "end_byte": 66, + "start_point": { + "row": 4, + "column": 12 + }, + "end_point": { + "row": 4, + "column": 16 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "block", + "children": [ + [ + "statements", + { + "codegen_sdk_type": "MultiLineCollection", + "span": { + "range": { + "start_byte": 62, + "end_byte": 66, + "start_point": { + "row": 4, + "column": 12 + }, + "end_point": { + "row": 4, + "column": 16 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "block", + "children": [ + [ + null, + { + "codegen_sdk_type": "PyPassStatement", + "span": { + "range": { + "start_byte": 62, + "end_byte": 66, + "start_point": { + "row": 4, + "column": 12 + }, + "end_point": { + "row": 4, + "column": 16 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "pass_statement", + "children": [] + } + ] + ] + } + ] + ] + } + ] + ] + } + ] + ] + } + ] + ] + } + ] + ] + } + ] + ] + } + ] + ] + } + ], + [ + null, + { + "codegen_sdk_type": "Name", + "span": { + "range": { + "start_byte": 22, + "end_byte": 25, + "start_point": { + "row": 2, + "column": 10 + }, + "end_point": { + "row": 2, + "column": 13 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "identifier", + "children": [] + } + ], + [ + null, + { + "codegen_sdk_type": "Name", + "span": { + "range": { + "start_byte": 39, + "end_byte": 42, + "start_point": { + "row": 3, + "column": 12 + }, + "end_point": { + "row": 3, + "column": 15 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "identifier", + "children": [] + } + ], + [ + null, + { + "codegen_sdk_type": "Name", + "span": { + "range": { + "start_byte": 43, + "end_byte": 47, + "start_point": { + "row": 3, + "column": 16 + }, + "end_point": { + "row": 3, + "column": 20 + } + }, + "filepath": "test.py" + }, + "tree_sitter_type": "identifier", + "children": [] + } + ] + ] }