Did I find the right examples for you? yes no

All Samples(37)  |  Call(37)  |  Derive(0)  |  Import(0)

src/o/e/oe-core-HEAD/meta/lib/oeqa/selftest/bbtests.py   oe-core(Download)
        find_build_started = re.search("NOTE: Test for bb\.event\.BuildStarted(\n.*)*NOTE: Preparing runqueue", result.output)
        find_build_completed = re.search("Tasks Summary:.*(\n.*)*NOTE: Test for bb\.event\.BuildCompleted", result.output)
        self.assertTrue(find_build_started, msg = "Match failed in:\n%s"  % result.output)
        self.assertTrue(find_build_completed, msg = "Match failed in:\n%s" % result.output)
        self.assertFalse('Test for bb.event.InvalidEvent' in result.output)
        result = bitbake('m4-native')
        find_setscene = re.search("m4-native.*do_.*_setscene", result.output)
        self.assertTrue(find_setscene)
 
    def test_bitbake_invalid_recipe(self):
        result = bitbake('-b asdf', ignore_status=True)
        self.assertTrue("ERROR: Unable to find any recipe file matching 'asdf'" in result.output)
    def test_bitbake_invalid_target(self):
        result = bitbake('asdf', ignore_status=True)
        self.assertTrue("ERROR: Nothing PROVIDES 'asdf'" in result.output)
 
    def test_warnings_errors(self):

src/o/e/oe-core-HEAD/meta/lib/oeqa/selftest/prservice.py   oe-core(Download)
        package_data = ftools.read_file(package_data_file)
        find_pr = re.search("PKGR: r[0-9]+\.([0-9]+)", package_data)
        self.assertTrue(find_pr)
        return int(find_pr.group(1))
 
        self.delete_recipeinc(package_name)
        self.assertEqual(res.status, 0, msg=res.output)
        self.assertTrue("NOTE: Started PRServer with DBfile" in res.output, msg=res.output)
 
    def config_pr_tests(self, package_name, package_type='rpm', pr_socket='localhost:0'):
 
        bitbake("-ccleansstate %s" % package_name)
        self.assertTrue(pr_2 - pr_1 == 1)
        self.assertTrue(stamp_1 != stamp_2)
 
        if replace_current_db:
            current_db_path = os.path.join(get_bb_var('PERSISTENT_DIR'), 'prserv.sqlite3')
            self.assertTrue(os.path.exists(current_db_path), msg="Path to current PR Service database is invalid: %s" % current_db_path)
            os.remove(current_db_path)
 

src/o/e/oe-core-HEAD/meta/lib/oeqa/selftest/buildhistory.py   oe-core(Download)
            self.assertEqual(result.status, 1, msg="Error expected for global config '%s' and target config '%s'" % (global_config, target_config))
            search_for_error = re.search(error_regex, result.output)
            self.assertTrue(search_for_error, msg="Could not find desired error in output: %s" % error_regex)
        else:
            self.assertEqual(result.status, 0, msg="Command 'bitbake %s' has failed unexpectedly: %s" % (target, result.output))

src/o/e/oe-core-HEAD/meta/lib/oeqa/selftest/bblayers.py   oe-core(Download)
    def test_bitbakelayers_showcrossdepends(self):
        result = runCmd('bitbake-layers show-cross-depends')
        self.assertTrue('aspell' in result.output)
 
    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')
        self.assertTrue('aspell' in result.output, msg='xcursor-transparent-theme_0.1.1.bbappend file was not recognised')
    def test_bitbakelayers_flatten(self):
        self.assertFalse(os.path.isdir(os.path.join(self.builddir, 'test')))
        result = runCmd('bitbake-layers flatten test')
        bb_file = os.path.join(self.builddir, 'test/recipes-graphics/xcursor-transparent-theme/xcursor-transparent-theme_0.1.1.bb')
        self.assertTrue(os.path.isfile(bb_file))

src/o/e/oe-core-HEAD/meta/lib/oeqa/selftest/buildoptions.py   oe-core(Download)
    def test_ccache_tool(self):
        bitbake("ccache-native")
        self.assertTrue(os.path.isfile(os.path.join(get_bb_var('STAGING_BINDIR_NATIVE', 'ccache-native'), "ccache")))
        self.write_config('INHERIT += "ccache"')
        bitbake("m4 -c cleansstate")
    def test_stoptask_behavior(self):
        self.write_config('BB_DISKMON_DIRS = "STOPTASKS,${TMPDIR},100000G,100K"')
        res = bitbake("m4", ignore_status = True)
        self.assertTrue('ERROR: No new tasks can be executed since the disk space monitor action is "STOPTASKS"!' in res.output)
        self.assertEqual(res.status, 1)
        self.write_config('BB_DISKMON_DIRS = "ABORT,${TMPDIR},100000G,100K"')
        res = bitbake("m4", ignore_status = True)
        self.assertTrue('ERROR: Immediately abort since the disk space monitor action is "ABORT"!' in res.output)
        self.write_config('BB_DISKMON_DIRS = "WARN,${TMPDIR},100000G,100K"')
        res = bitbake("m4")
        self.assertTrue('WARNING: The free space' in res.output)
 
class SanityOptionsTest(oeSelfTest):
        res = bitbake("xcursor-transparent-theme", ignore_status=True)
        self.delete_recipeinc('xcursor-transparent-theme')
        self.assertTrue("ERROR: QA Issue: xcursor-transparent-theme-dbg is listed in PACKAGES multiple times, this leads to packaging errors." in res.output)
        self.assertEqual(res.status, 1)
        self.write_recipeinc('xcursor-transparent-theme', 'PACKAGES += \"${PN}-dbg\"')