This directory contains test scripts and unit tests to verify the functionality of the UniFi Network Rules integration.
The integration includes a suite of unit tests to verify the functionality of various components:
test_api.py: Tests for the core API functionalitytest_firewall.py: Tests for the firewall management APItest_static_routes.py: Tests for static routes functionality (models, API, switches, integration)
To run the unit tests:
pytest tests/To run a specific test file:
pytest tests/test_api.py
pytest tests/test_static_routes.pyTo run with coverage report:
pytest tests/ --cov=custom_components.unifi_network_rules