kiwi-el8/test/unit/bootloader/install/base_test.py
Marcus Schäfer 9c9250ebc4
Support nose and xunit style tests
The modifications in this commit allows the unit tests
to run on both, pytest 6.x (nose test layout) and the new
pytest 7.x (xunit test layout). This Fixes #2072 in a
much nicer way. Thanks much to @smarlowucf
2022-02-26 20:26:18 +01:00

27 lines
682 B
Python

from mock import Mock
from pytest import raises
from kiwi.bootloader.install.base import BootLoaderInstallBase
class TestBootLoaderInstallBase:
def setup(self):
self.bootloader = BootLoaderInstallBase(
'root_dir', Mock()
)
def setup_method(self, cls):
self.setup()
def test_install(self):
with raises(NotImplementedError):
self.bootloader.install()
def test_install_required(self):
with raises(NotImplementedError):
self.bootloader.install_required()
def test_secure_boot_install(self):
with raises(NotImplementedError):
self.bootloader.secure_boot_install()