Skip to content

Commit 95eb1ba

Browse files
authored
Merge pull request #9701 from Geometror/tests-add-special-tags-section
Add section about special tags to the unit testing guide
2 parents 1b974d5 + b85d63c commit 95eb1ba

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

contributing/development/core_and_modules/unit_testing.rst

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -260,6 +260,25 @@ the engine, for instance:
260260
"Invalid HTML notation should result in a Color with the default values.");
261261
}
262262
263+
Special tags in test case names
264+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
265+
266+
These tags can be added to the test case name to modify or extend the test environment:
267+
268+
+-------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
269+
| **Tag** | **Description** |
270+
+-------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
271+
| ``[SceneTree]`` | Required for test cases that rely on a scene tree with MessageQueue to be available. It also enables a mock rendering server and :ref:`ThemeDB<class_ThemeDB>`. |
272+
+-------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
273+
| ``[Editor]`` | Like ``[SceneTree]``, but with additional editor-related infrastructure available, such as :ref:`EditorSettings<class_EditorSettings>`. |
274+
+-------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
275+
| ``[Audio]`` | Initializes the :ref:`AudioServer<class_AudioServer>` using a mock audio driver. |
276+
+-------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
277+
| ``[Navigation]`` | Creates the default 2D/3D navigation servers and makes them available for testing. |
278+
+-------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+
279+
280+
You can use them together to combine multiple test environment extensions.
281+
263282
Test tools
264283
----------
265284

0 commit comments

Comments
 (0)