On Thu, Dec 12, 2019 at 10:14:45PM +0100, Till Maas wrote:
while looking at Nmstate logs after failures I noticed that Nmstate
uses checkpoints in the tear-up phase of integration tests. Therefore,
if something fails inside the mainloopo in the tear-up phase, all
tear-up progress is reverted instead of keeping at least the removed
bits removed. Am I missing something?
The design is ideal for user, not for test.
To support case like this, we can add support of `skip_checkpoint` to
All the tear up should using `verify_change=False` and expected not
If there is a failure, we should look into it.
From my memory, most of them are caused by OVS which is known issue.
My idea for the easiest/cleanest solution would be to just issue
"nmcli c d $interface; nmclid d $interface (if it is not eth1/eth2)"
and ignoring the returncode for all interfaces that are touched in a
test as the tear-up code. Since Nmstate also stores routes and DNS
information in the respective profiles, this should properly clean it
up with the better working nmcli code.
There was a patch from me doing:
* store nmstate state before test and apply back after test.
* use `nmcli c del` to delete test interfaces.
But that was rejected by Edy about:
* We are supposed to do clean in test also.
* Doing so will hide the clean up leftover.
And I agree with Edy.