Did I find the right examples for you? yes no

All Samples(28)  |  Call(18)  |  Derive(0)  |  Import(10)

src/o/e/oe-core-HEAD/meta/lib/oeqa/controllers/masterimage.py   oe-core(Download)
    def power_ctl(self, msg):
        if self.powercontrol_cmd:
            cmd = "%s %s" % (self.powercontrol_cmd, msg)
            try:
                commands.runCmd(cmd, assert_error=False, preexec_fn=os.setsid, env=self.origenv)

src/o/e/oe-core-HEAD/meta/lib/oeqa/selftest/_sstatetests_noauto.py   oe-core(Download)
import oeqa.utils.ftools as ftools
from oeqa.selftest.base import oeSelfTest
from oeqa.utils.commands import runCmd, bitbake, get_bb_var, get_test_layer
from oeqa.selftest.sstate import SStateBase
 
 
        self.configure_builddir(buildA)
        runCmd((". %s/oe-init-build-env %s && " % (get_bb_var('COREBASE'), buildA)) + 'bitbake  ' + ' '.join(map(str, primary_targets)), shell=True, executable='/bin/bash')
        self.hardlink_tree(os.path.join(buildA, 'sstate-cache'), os.path.join(self.builddir, 'sstate-cache-buildA'))
        shutil.rmtree(buildA)
            self.hardlink_tree(os.path.join(self.builddir, 'sstate-cache-buildA'), os.path.join(buildB, 'sstate-cache'))
 
            result_cleansstate = runCmd((". %s/oe-init-build-env %s && " % (get_bb_var('COREBASE'), buildB)) + 'bitbake -ccleansstate ' + target, ignore_status=True, shell=True, executable='/bin/bash')
            if not result_cleansstate.status == 0:
                failed_cleansstate.append(target)
                shutil.rmtree(buildB)
                continue
 
            result_build = runCmd((". %s/oe-init-build-env %s && " % (get_bb_var('COREBASE'), buildB)) + 'bitbake ' + target, ignore_status=True, shell=True, executable='/bin/bash')

src/o/e/oe-core-HEAD/meta/lib/oeqa/selftest/buildoptions.py   oe-core(Download)
from oeqa.selftest.base import oeSelfTest
from oeqa.selftest.buildhistory import BuildhistoryBase
from oeqa.utils.commands import runCmd, bitbake, get_bb_var
import oeqa.utils.ftools as ftools
 
        self.append_config('IMAGE_FEATURES += "ssh-server-openssh"')
        bitbake("core-image-minimal")
        res = runCmd("grep 'Installing openssh-sshd' %s" % (os.path.join(get_bb_var("WORKDIR", "core-image-minimal"), "temp/log.do_rootfs")), ignore_status=True)
        self.remove_config('IMAGE_FEATURES += "ssh-server-openssh"')
        self.assertEqual(0, res.status, msg="No match for openssh-sshd in log.do_rootfs")
        bitbake("core-image-minimal")
        res = runCmd("grep 'Removing openssh-sshd' %s" %(os.path.join(get_bb_var("WORKDIR", "core-image-minimal"), "temp/log.do_rootfs")),ignore_status=True)
        bitbake("m4 -c cleansstate")
        bitbake("m4 -c compile")
        res = runCmd("grep ccache %s" % (os.path.join(get_bb_var("WORKDIR","m4"),"temp/log.do_compile")), ignore_status=True)
        self.assertEqual(0, res.status, msg="No match for ccache in m4 log.do_compile")
        bitbake("ccache-native -ccleansstate")

src/o/e/oe-core-HEAD/meta/lib/oeqa/selftest/prservice.py   oe-core(Download)
import oeqa.utils.ftools as ftools
from oeqa.selftest.base import oeSelfTest
from oeqa.utils.commands import runCmd, bitbake, get_bb_var
 
class BitbakePrTests(oeSelfTest):
 
        exported_db_path = os.path.join(self.builddir, 'export.inc')
        export_result = runCmd("bitbake-prserv-tool export %s" % exported_db_path, ignore_status=True)
        self.assertEqual(export_result.status, 0, msg="PR Service database export failed: %s" % export_result.output)
 
            os.remove(current_db_path)
 
        import_result = runCmd("bitbake-prserv-tool import %s" % exported_db_path, ignore_status=True)
        os.remove(exported_db_path)
        self.assertEqual(import_result.status, 0, msg="PR Service database import failed: %s" % import_result.output)

src/o/e/oe-core-HEAD/meta/lib/oeqa/selftest/base.py   oe-core(Download)
 
import oeqa.utils.ftools as ftools
from oeqa.utils.commands import runCmd, bitbake, get_bb_var, get_test_layer
 
class oeSelfTest(unittest.TestCase):
    def tearDown(self):
        if self._extra_tear_down_commands:
            failed_extra_commands = []
            for command in self._extra_tear_down_commands:
                result = runCmd(command, ignore_status=True)

src/o/e/oe-core-HEAD/meta/lib/oeqa/selftest/oescripts.py   oe-core(Download)
from oeqa.selftest.base import oeSelfTest
from oeqa.selftest.buildhistory import BuildhistoryBase
from oeqa.utils.commands import Command, runCmd, bitbake, get_bb_var, get_test_layer
 
class TestScripts(oeSelfTest):
        intermediary_contents = os.listdir(path)
        bitbake("-b %s" % old_version_recipe)
        runCmd('cleanup-workdir')
        remaining_contents = os.listdir(path)
 
        self.run_buildhistory_operation(target, target_config="PR = \"r1\"", change_bh_location=True)
        self.run_buildhistory_operation(target, target_config="PR = \"r0\"", change_bh_location=False, expect_error=True)
        result = runCmd("buildhistory-diff -p %s" % get_bb_var('BUILDHISTORY_DIR'))
        expected_output = 'PR changed from "r1" to "r0"'
        self.assertTrue(expected_output in result.output, msg="Did not find expected output: %s" % result.output)

src/o/e/oe-core-HEAD/meta/lib/oeqa/selftest/sstatetests.py   oe-core(Download)
import oeqa.utils.ftools as ftools
from oeqa.selftest.base import oeSelfTest
from oeqa.utils.commands import runCmd, bitbake, get_bb_var, get_test_layer
from oeqa.selftest.sstate import SStateBase
 
            self.assertEqual(result.status, 0)
 
        runCmd("sstate-cache-management.sh -y --cache-dir=%s --remove-duplicated --extra-archs=%s" % (self.sstate_path, ','.join(map(str, sstate_archs_list))))
        actual_remaining_sstate = [x for x in self.search_sstate(target + '.*?\.tgz$') if not any(pattern in x for pattern in ignore_patterns)]
 

src/o/e/oe-core-HEAD/meta/lib/oeqa/selftest/bblayers.py   oe-core(Download)
import oeqa.utils.ftools as ftools
from oeqa.selftest.base import oeSelfTest
from oeqa.utils.commands import runCmd
 
class BitbakeLayers(oeSelfTest):
 
    def test_bitbakelayers_showcrossdepends(self):
        result = runCmd('bitbake-layers show-cross-depends')
    def test_bitbakelayers_showlayers(self):
        result = runCmd('bitbake-layers show_layers')
        self.assertTrue('meta-selftest' in result.output)
 
    def test_bitbakelayers_showappends(self):
        result = runCmd('bitbake-layers show_appends')
        self.assertTrue('xcursor-transparent-theme_0.1.1.bbappend' in result.output, msg='xcursor-transparent-theme_0.1.1.bbappend file was not recognised')
 
    def test_bitbakelayers_showoverlayed(self):
        result = runCmd('bitbake-layers show_overlayed')

src/o/e/oe-core-HEAD/meta/lib/oeqa/selftest/sstate.py   oe-core(Download)
import oeqa.utils.ftools as ftools
from oeqa.selftest.base import oeSelfTest
from oeqa.utils.commands import runCmd, bitbake, get_bb_var, get_test_layer
 
 

src/o/e/oe-core-HEAD/meta/lib/oeqa/selftest/buildhistory.py   oe-core(Download)
import oeqa.utils.ftools as ftools
from oeqa.selftest.base import oeSelfTest
from oeqa.utils.commands import Command, runCmd, bitbake, get_bb_var, get_test_layer
 
 

  1 | 2  Next