mongo/docs/testing/resmoke_modules.md
Steve McClure 32e8f260de SERVER-124136 Format markdown via prettier: wrap lines and use width of 100 (#52231)
GitOrigin-RevId: 3305c1e2ee3a6a2c3a5b2b7883b0f491a59ed646
2026-04-21 19:20:11 +00:00

41 lines
1.5 KiB
Markdown

# Resmoke Module Configuration
This configuration allows additional modules to be added to Resmoke, providing more context about
their associated directories. Modules can specify directories for fixtures, hooks, suites, and
JavaScript tests, which Resmoke incorporates during its testing process.
## Adding a New Module
To add a new module to Resmoke, define the module name and specify its `fixture_dirs`, `hook_dirs`,
`suite_dirs`, and `jstest_dirs` in the YAML configuration. Each field should be a list of directory
paths.
### Example YAML Configuration
```yaml
my_new_module:
fixture_dirs:
- path/to/my_new_module/fixtures
hook_dirs:
- path/to/my_new_module/hooks
suite_dirs:
- path/to/my_new_module/suites
jstest_dirs:
- path/to/my_new_module/jstests
```
### Field Descriptions
- **`fixture_dirs`**: Directories containing fixtures associated with the module.
- **`hook_dirs`**: Directories containing hooks associated with the module.
- **`suite_dirs`**: Directories containing suites with test configurations.
- **`jstest_dirs`**: Directories containing JavaScript tests specific to the module. This ensures
module-specific tests are excluded from other suite configurations when the module is disabled.
## Notes
- Any suite can use jstests from any directory, when the module is enabled the configured jstest
dirs does nothing. Only when the module is disabled does it filter out the tests that might be
configured in a suite from a different module.
- Fields can be omitted or empty lists