This is an automated email from the ASF dual-hosted git repository.
spacewander pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/apisix.git
The following commit(s) were added to refs/heads/master by this push:
new a62fd93 docs: improve docs about testing (#5377)
a62fd93 is described below
commit a62fd939321287b904d95aa25679c0dbb52c211c
Author: Yujia Qiao <[email protected]>
AuthorDate: Sun Oct 31 19:22:42 2021 +0800
docs: improve docs about testing (#5377)
---
CONTRIBUTING.md | 1 +
docs/en/latest/how-to-build.md | 4 +++-
docs/zh/latest/how-to-build.md | 4 +++-
3 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index bf69bb9..a418914 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -126,6 +126,7 @@ Once we've discussed your changes and you've got your code
ready, make sure that
* Use tool to check your test case style statically by command, eg: `make
lint`.
* When the test file is too large, for example > 800 lines, you should
split it to a new file.
Please take a look at `t/plugin/limit-conn.t` and
`t/plugin/limit-conn2.t`.
+ * For more details, see the [testing
framework](https://github.com/apache/apisix/blob/master/docs/en/latest/internal/testing-framework.md)
## Do you have questions about the source code?
diff --git a/docs/en/latest/how-to-build.md b/docs/en/latest/how-to-build.md
index 8a2d898..c72adca 100644
--- a/docs/en/latest/how-to-build.md
+++ b/docs/en/latest/how-to-build.md
@@ -178,7 +178,7 @@ apisix help
git clone https://github.com/iresty/test-nginx.git
```
-4. Load the test-nginx library with the `prove` command in `perl` and run the
test case set in the `/t` directory.
+4. Here are two ways of running tests:
- Append the current directory to the perl module directory: `export
PERL5LIB=.:$PERL5LIB`, then run `make test` command.
@@ -220,6 +220,8 @@ Run the specified test case using the following command.
prove -Itest-nginx/lib -r t/plugin/openid-connect.t
```
+For more details on the test cases, see the [testing
framwork](https://github.com/apache/apisix/blob/master/docs/en/latest/internal/testing-framework.md).
+
## Step 5: Update Admin API token to Protect Apache APISIX
You need to modify the Admin API key to protect Apache APISIX.
diff --git a/docs/zh/latest/how-to-build.md b/docs/zh/latest/how-to-build.md
index bfbcd83..39e98f0 100644
--- a/docs/zh/latest/how-to-build.md
+++ b/docs/zh/latest/how-to-build.md
@@ -176,7 +176,7 @@ apisix help
git clone https://github.com/iresty/test-nginx.git
```
-4. 通过 `perl` 的 `prove` 命令来加载 test-nginx 的库,并运行 `/t` 目录下的测试案例集:
+4. 有两种方法运行测试:
- 追加当前目录到perl模块目录: `export PERL5LIB=.:$PERL5LIB`,然后运行 `make test` 命令。
@@ -218,6 +218,8 @@ apisix help
prove -Itest-nginx/lib -r t/plugin/openid-connect.t
```
+关于测试用例的更多细节,参见[测试框架](https://github.com/apache/apisix/blob/master/docs/en/latest/internal/testing-framework.md)
+
## 步骤5:修改 Admin API key
您需要修改 Admin API 的 key,以保护 Apache APISIX。