File: tests.md

package info (click to toggle)
anta 1.7.0-2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 8,048 kB
  • sloc: python: 48,164; sh: 28; javascript: 9; makefile: 4
file content (99 lines) | stat: -rw-r--r-- 3,145 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
---
anta_title: ANTA Tests
---
<!--
  ~ Copyright (c) 2023-2025 Arista Networks, Inc.
  ~ Use of this source code is governed by the Apache License 2.0
  ~ that can be found in the LICENSE file.
  -->

This section describes all the available tests provided by the ANTA package.

## Available Tests

Here are the tests that we currently provide:

- [AAA](tests/aaa.md)
- [Adaptive Virtual Topology](tests/avt.md)
- [BFD](tests/bfd.md)
- [Configuration](tests/configuration.md)
- [Connectivity](tests/connectivity.md)
- [CVX](tests/cvx.md)
- [EVPN](tests/evpn.md)
- [Field Notices](tests/field_notices.md)
- [Flow Tracking](tests/flow_tracking.md)
- [GreenT](tests/greent.md)
- [Hardware](tests/hardware.md)
- [Interfaces](tests/interfaces.md)
- [LANZ](tests/lanz.md)
- [Logging](tests/logging.md)
- [MLAG](tests/mlag.md)
- [Multicast](tests/multicast.md)
- [Profiles](tests/profiles.md)
- [PTP](tests/ptp.md)
- [Router Path Selection](tests/path_selection.md)
- [Routing Generic](tests/routing.generic.md)
- [Routing BGP](tests/routing.bgp.md)
- [Routing ISIS](tests/routing.isis.md)
- [Routing OSPF](tests/routing.ospf.md)
- [Security](tests/security.md)
- [Services](tests/services.md)
- [SNMP](tests/snmp.md)
- [Software](tests/software.md)
- [STP](tests/stp.md)
- [STUN](tests/stun.md)
- [System](tests/system.md)
- [VLAN](tests/vlan.md)
- [VXLAN](tests/vxlan.md)

!!! tip

    You can use `anta get tests` from the CLI to list all the tests available with an example. Refer to [documentation](../cli/get-tests.md) for more options.

## Using the Tests

All these tests can be imported in a [catalog](../usage-inventory-catalog.md) to be used by [the ANTA CLI](../cli/nrfu.md) or in your [own framework](../advanced_usages/as-python-lib.md).

## Atomic result support

Tests marked with the following badge in the documentation support **Atomic Results**: <img alt="Atomic support badge" src="https://img.shields.io/badge/Atomic%20result%20support-brightgreen?style=flat&logoSize=auto">

This means that when `anta nrfu <command>` is run with the `--expand` flag (currently supported for `table` and `text`), the report expands the test results to show one entry per input.

For instance, consider the following inventory and catalog:

```yaml title="inventory.yml"
---
anta_inventory:
  hosts:
    - host: 10.42.42.42
      name: pf1
```

```yaml title="catalog.yml"
---
anta.tests.connectivity:
  - VerifyReachability:
      hosts:
        - destination: 8.8.8.8
          vrf: MGMT
        - destination: 8.8.4.4
          vrf: default
```

**Normal Run:**

![anta nrfu table](../imgs/anta_nrfu_table.svg){ loading=lazy width="1600" }

**Expanded Run:**

![anta nrfu table](../imgs/anta_nrfu_table_expand.svg){ loading=lazy width="1600" }

!!! warning

    If the command collection fails for any reason, the results for that test will not be expanded.
    This includes command collection failures based on [known EOS errors](./commands.md#anta.constants.KNOWN_EOS_ERRORS) tracked by ANTA.

!!! info

    If you would like a test to support atomic results, please [open an issue on GitHub](https://github.com/aristanetworks/anta/issues)