omkar619-dev opened a new pull request, #14227: URL: https://github.com/apache/apisix/pull/14227
### Description The [macOS development environment guide](https://github.com/apache/apisix/blob/64d831f4f389ad652eb9b180fd4fd5f9c794b5b0/docs/en/latest/build-apisix-dev-environment-on-mac.md) clones APISIX and then runs test cases with `prove` in the dev container, for example `prove t/admin/routes.t`. The test cases load `toolkit.json` from the `t/toolkit` submodule ([test_admin.lua L18](https://github.com/apache/apisix/blob/64d831f4f389ad652eb9b180fd4fd5f9c794b5b0/t/lib/test_admin.lua#L18)), but a plain `git clone` leaves `t/toolkit` empty, so every test that uses the admin helper fails: ```txt lua entry thread aborted: runtime error: /apisix/t/lib/test_admin.lua:18: module 'toolkit.json' not found: ``` `make test` does not run into this, because it runs `git submodule update --init --recursive` first ([Makefile L444](https://github.com/apache/apisix/blob/64d831f4f389ad652eb9b180fd4fd5f9c794b5b0/Makefile#L444)), and CI checks out with `submodules: recursive` ([build.yml L46](https://github.com/apache/apisix/blob/64d831f4f389ad652eb9b180fd4fd5f9c794b5b0/.github/workflows/build.yml#L46)). The guide calls `prove` directly, so it needs the step itself. This PR adds `git submodule update --init t/toolkit` after `cd apisix` in the English and Chinese guides, and mentions the submodule in the sentence before the commands. It fetches only `t/toolkit`, which is small. The other two submodules are GitHub Actions that only CI uses, and together they are about 45 MB. Testing, in the dev container from the guide (Docker Desktop on an Apple silicon Mac): - Without `t/toolkit`, `prove t/admin/routes.t` fails with the error above. - After `git submodule update --init t/toolkit`, it passes. - markdownlint, autocorrect and `utils/fix-zh-doc-segment.py` pass on both files. #### Which issue(s) this PR fixes: There is no issue for this. I ran into it while following the guide. ### Checklist - [x] I have explained the need for this PR and the problem it solves - [x] I have explained the changes or the new features added to this PR - [ ] I have added tests corresponding to this change - [x] I have updated the documentation to reflect this change - [x] I have verified that this change is backward compatible (If not, please discuss on the [APISIX mailing list](https://github.com/apache/apisix/tree/master#community) first) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
