OSInside / kiwi

KIWI - Appliance Builder Next Generation
https://osinside.github.io/kiwi
GNU General Public License v3.0
283 stars 144 forks source link

Fixup cleanup of zipl templates #2508

Closed schaefi closed 4 months ago

schaefi commented 4 months ago

Make sure temporary modifications to the zipl template and config file are not effective in the later system. This Fixes bsc#1221469

Vogtinator commented 4 months ago

LGTM, but I'm a bit surprised that it didn't impact any existing tests

schaefi commented 4 months ago

LGTM, but I'm a bit surprised that it didn't impact any existing tests

Thanks. The problem was that the restore of the template files only happened for CDL targets when it should happen always. In the tests we had tested the cleanup for CDL and we didn't had a test to test the "no cleanup" situation. The change here causes the cleanup code to happen always which still keeps the existing test functional. I think the issue was that we didn't had a test for the "no cleanup" condition. Maybe if we would have had that test we would have asked ourselves if that's not a mistake... sounds philosophical doesn't it :)