mirror of
https://github.com/VictoriaMetrics/VictoriaMetrics.git
synced 2024-12-05 01:01:09 +01:00
docs: fix rule unittest rule_files point to alerts.yaml (#7664)
### Describe Your Changes Fix wrong path to rules_file in vmalert-tool doc ### Checklist The following checks are **mandatory**: - [x] My change adheres [VictoriaMetrics contributing guidelines](https://docs.victoriametrics.com/contributing/). Signed-off-by: Viet Hung Nguyen <hvn@familug.org> Co-authored-by: Hui Wang <haley@victoriametrics.com>
This commit is contained in:
parent
cdbe69e62b
commit
466cbee433
@ -197,9 +197,9 @@ value: <number>
|
|||||||
### Example
|
### Example
|
||||||
|
|
||||||
This is an example input file for unit testing which will pass.
|
This is an example input file for unit testing which will pass.
|
||||||
`test.yaml` is the test file which follows the syntax above and `alerts.yaml` contains the alerting rules.
|
`test.yaml` is the test file which follows the syntax above and `rules.yaml` contains the alerting rules.
|
||||||
|
|
||||||
With `rules.yaml` in the same directory, run `./vmalert-tool unittest --files=./unittest/testdata/test.yaml -external.label=cluster=prod`.
|
With `rules.yaml` in the same directory with `test.yaml`, run `./vmalert-tool unittest --files=./unittest/testdata/test.yaml -external.label=cluster=prod`.
|
||||||
|
|
||||||
#### `test.yaml`
|
#### `test.yaml`
|
||||||
|
|
||||||
@ -249,7 +249,7 @@ tests:
|
|||||||
exp_alerts: []
|
exp_alerts: []
|
||||||
```
|
```
|
||||||
|
|
||||||
#### `alerts.yaml`
|
#### `rules.yaml`
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
# This is the rules file.
|
# This is the rules file.
|
||||||
|
Loading…
Reference in New Issue
Block a user