[pve-devel] [PATCH v2 pve-network 0/5] SDN tests in sbuild

Max Carrara m.carrara at proxmox.com
Mon Mar 25 14:24:43 CET 2024


On Thu Mar 7, 2024 at 4:13 PM CET, Stefan Lendl wrote:
> Extract and mock functions that otherwise access system files which is not
> possible in a clean sbuild environment.
> Namely /etc/network/interfaces as well as /etc/frr/frr.config.local
> Disabling DNS tests
>
> Changes v1 -> v2:
> * Disabled DNS tests because they fail
>

Looked through it all and ran the tests manually and also indirectly via
builds - looks pretty good to me! Always fond of making things more
testable! :)

There are some minor comments inline - but one important thing: The DNS
tests are passing for me. Maybe double-check if they pass for you now
too; if that's the case, patch #4 can just be dropped, as mentioned in
my comment.

Otherwise:

Reviewed-by: Max Carrara <m.carrara at proxmox.com>
Tested-by: Max Carrara <m.carrara at proxmox.com>

>
> Stefan Lendl (5):
>   refactor(controllers): extract read_etc_network_interfaces
>   refactor(evpn): extract read_local_frr_config
>   tests: mocking more functions to avoid system access
>   tests: disable failing DNS tests
>   tests: run tests in sbuild
>
>  src/Makefile                                  |  2 +-
>  src/PVE/Network/SDN/Controllers.pm            | 16 ++++++---
>  src/PVE/Network/SDN/Controllers/EvpnPlugin.pm | 10 ++++--
>  src/test/Makefile                             |  2 +-
>  src/test/run_test_zones.pl                    | 36 ++++++++++++++++++-
>  5 files changed, 56 insertions(+), 10 deletions(-)





More information about the pve-devel mailing list