summaryrefslogtreecommitdiffstats
path: root/meta/lib/oeqa/runtime/cases/opkg.py
diff options
context:
space:
mode:
Diffstat (limited to 'meta/lib/oeqa/runtime/cases/opkg.py')
-rw-r--r--meta/lib/oeqa/runtime/cases/opkg.py23
1 files changed, 18 insertions, 5 deletions
diff --git a/meta/lib/oeqa/runtime/cases/opkg.py b/meta/lib/oeqa/runtime/cases/opkg.py
index 671ee06c73..a29c93e59a 100644
--- a/meta/lib/oeqa/runtime/cases/opkg.py
+++ b/meta/lib/oeqa/runtime/cases/opkg.py
@@ -1,7 +1,13 @@
+#
+# Copyright OpenEmbedded Contributors
+#
+# SPDX-License-Identifier: MIT
+#
+
import os
from oeqa.utils.httpserver import HTTPService
from oeqa.runtime.case import OERuntimeTestCase
-from oeqa.core.decorator.data import skipIfNotDataVar, skipIfNotFeature
+from oeqa.core.decorator.data import skipIfNotDataVar, skipIfNotFeature, skipIfFeature
from oeqa.runtime.decorator.package import OEHasPackage
class OpkgTest(OERuntimeTestCase):
@@ -16,13 +22,18 @@ class OpkgTest(OERuntimeTestCase):
class OpkgRepoTest(OpkgTest):
@classmethod
- def setUpClass(cls):
- service_repo = os.path.join(cls.tc.td['DEPLOY_DIR_IPK'], 'all')
- cls.repo_server = HTTPService(service_repo, cls.tc.target.server_ip)
+ def setUp(cls):
+ allarchfeed = 'all'
+ if cls.tc.td["MULTILIB_VARIANTS"]:
+ allarchfeed = cls.tc.td["TUNE_PKGARCH"]
+ service_repo = os.path.join(cls.tc.td['DEPLOY_DIR_IPK'], allarchfeed)
+ cls.repo_server = HTTPService(service_repo,
+ '0.0.0.0', port=cls.tc.target.server_port,
+ logger=cls.tc.logger)
cls.repo_server.start()
@classmethod
- def tearDownClass(cls):
+ def tearDown(cls):
cls.repo_server.stop()
def setup_source_config_for_package_install(self):
@@ -38,6 +49,8 @@ class OpkgRepoTest(OpkgTest):
'Test requires package-management to be in IMAGE_FEATURES')
@skipIfNotDataVar('IMAGE_PKGTYPE', 'ipk',
'IPK is not the primary package manager')
+ @skipIfFeature('read-only-rootfs',
+ 'Test does not work with read-only-rootfs in IMAGE_FEATURES')
@OEHasPackage(['opkg'])
def test_opkg_install_from_repo(self):
self.setup_source_config_for_package_install()