Introduction

YANG Verifiers is a Python library used to create custom YANG verifiers for the pyATS Genie Blitz "yang" action. The default YANG verifier consumes the YANG response, decodes it into Xpath/value tuples, and compares those values to the Xpath/value returns defined in the Genie YAML test. This is effective, but very simple, and does not scale.

Having a custom verifier allows users to consume the same YANG response, decode it using the default verifier, or, create a custom decoder, and perform other tasks that are currently not available.

For example, scale testing is always a challenge. A Genie test is written in YAML with static values to validate YANG responses and is not feasible when dealing with hundreds of thousands of responses over a long period of time. With a custom verifier, calls can be made to devices, databases, or text files for static or dynamic data to be used to validate YANG responses.

Another example would be to have the custom verifier save test results and other test details into an InfluxDB database with a Grafana dashboard. The Grafana dashboard can be displayed to managers or marketing to track progress or monitor regression.

The custom verifier provides a window of opportunity to perform any desired action on decoded YANG responses.