You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -20,26 +20,26 @@ DragonOS integrates the gVisor system call test suite to verify the compatibilit
20
20
Overview
21
21
========
22
22
23
-
gVisor is a container runtime sandbox developed by Google, which includes a comprehensive set of system call compatibility tests. These tests are designed to validate whether an operating system's system call implementation complies with Linux standards.
23
+
gVisor is a container runtime sandbox developed by Google, which includes a comprehensive set of system call compatibility tests. These tests are designed to validate whether an operating system's system call implementations comply with Linux standards.
24
24
25
25
Key Features:
26
26
27
27
- **Comprehensive Test Coverage**: Contains hundreds of system call test cases
28
28
- **Whitelist Mechanism**: By default, only verified tests are executed, with support gradually expanding
29
29
- **Blacklist Filtering**: Allows blocking specific test cases for each test program
30
-
- **Automated Execution**: Provides Makefile and scripts to simplify the testing process
30
+
- **Automated Execution**: Provides Makefiles and scripts to simplify the testing process
31
31
32
32
Automated Testing
33
33
==========
34
34
35
-
Execute the `make test-syscall` command. This command will launch DragonOS and automatically execute the gvisor syscall test suite. After testing completes, it will exit qemu. The return status will be success or failure based on the test case success rate - returning failure if the success rate is not 100%. The execution flow of this command is as follows:
35
+
Execute the `make test-syscall` command. This command will launch DragonOS and automatically execute the gvisor syscall test suite. After testing completes, it will exit qemu. The command will return success or failure based on the test case success rate - returning failure if the success rate is not 100%. The execution flow of this command is as follows:
36
36
37
-
1. Execute the configuration in `enable_compile_gvisor.sh` comment `app-blocklist.toml` regarding blocking the gvisor test suite
37
+
1. Execute `toggle_compile_gvisor.sh enable` to comment out the gvisor test suite-related blocking configurations in `app-blocklist.toml`
38
38
2. Compile DragonOS
39
39
3. Write the image
40
-
4. Start DragonOS in qemu background mode (without graphics), while setting environment variables `AUTO_TEST` (auto-test option, currently only supports syscall testing) and `SYSCALL_TEST_DIR` (test suite directory). These environment variables will be passed to DragonOS as command-line parameters. Then when the busybox init process executes the rcS script, this script will execute the corresponding test through the `AUTO_TEST` option
41
-
5. Execute `monitor_test_results.sh` to periodically check the qemu serial output content and determine success or failure return based on test results
42
-
6. Execute `disable_compile_gvisor.sh` to uncomment the configuration in `app-blocklist.toml` regarding blocking the gvisor test suite
40
+
4. Start DragonOS in the background in qemu's non-graphical mode, while setting environment variables `AUTO_TEST` (auto-test option, currently only supports syscall testing) and `SYSCALL_TEST_DIR` (directory where the test suite is located). These two environment variables will be passed to DragonOS as command-line parameters. Then, when the busybox init process executes the rcS script, this script will execute the corresponding tests through the `AUTO_TEST` option
41
+
5. Execute `monitor_test_results.sh` to periodically check the qemu serial port output content and determine whether to return success or failure based on the test results
42
+
6. Execute `toggle_compile_gvisor.sh disable` to uncomment the relevant configurations in `app-blocklist.toml`, restoring the default blocking state
43
43
44
44
The corresponding workflow configuration file is `test-x86.yml`
45
45
@@ -52,22 +52,21 @@ Manual Testing
52
52
53
53
cd user/apps/tests/syscall/gvisor
54
54
55
-
2. Run whitelist tests on Linux (automatically downloads the test suite):
55
+
2. Run whitelist tests in Linux (automatically downloads the test suite):
56
56
57
57
.. code-block:: bash
58
58
59
59
make test
60
60
61
-
3. If you need to run tests, first modify the configuration file:
61
+
3. If you need to run tests, you can quickly modify configurations via scripts:
62
62
63
-
Edit `config/app-blocklist.toml`, and comment out the following content:
63
+
.. code-block:: bash
64
64
65
-
.. code-block:: toml
65
+
# Enable gVisor testing (comment out blocklist configurations)
The test framework enables whitelist mode by default, running only the test programs specified in `_translated_label__`whitelist.txt`_en`. This allows for gradual verification of DragonOS's system call implementations.
92
+
The test framework enables whitelist mode by default, running only the test programs specified in `_translated_label__`whitelist.txt`_en`. This allows for gradual validation of DragonOS's system call implementations.
94
93
95
94
Blacklist Filtering
96
95
-----------
97
96
98
-
For each test program, specific test cases can be blocked through files in the `_translated_label__`blocklists/`_en` directory. This is particularly useful for skipping unsupported or unstable tests.
97
+
For each test program, specific test cases can be blocked through files in the `_translated_label__`blocklists/`_en` directory. This is particularly useful for skipping tests that are not yet supported or are unstable.
0 commit comments