summaryrefslogtreecommitdiffstats
path: root/meta-selftest
diff options
context:
space:
mode:
Diffstat (limited to 'meta-selftest')
-rw-r--r--meta-selftest/COPYING.MIT17
-rw-r--r--meta-selftest/conf/layer.conf2
-rw-r--r--meta-selftest/files/signing/key.passphrase1
-rw-r--r--meta-selftest/files/static-group14
-rw-r--r--meta-selftest/files/static-passwd11
-rw-r--r--meta-selftest/lib/devtool/bbpath.py44
-rw-r--r--meta-selftest/lib/oeqa/runtime/cases/dnf_runtime.py50
-rw-r--r--meta-selftest/lib/oeqa/runtime/cases/selftest.json (renamed from meta-selftest/lib/oeqa/runtime/selftest.json)0
-rw-r--r--meta-selftest/lib/oeqa/runtime/cases/selftest.py31
-rw-r--r--meta-selftest/lib/oeqa/runtime/cases/virgl.py18
-rw-r--r--meta-selftest/lib/oeqa/runtime/selftest.py55
-rw-r--r--meta-selftest/lib/oeqa/selftest/cases/external-layer.py16
-rw-r--r--meta-selftest/lib/recipetool/bbpath.py41
-rw-r--r--meta-selftest/recipes-devtools/python/python-async-test.inc16
-rw-r--r--meta-selftest/recipes-devtools/python/python3-async-test_0.6.2.bb2
-rw-r--r--meta-selftest/recipes-test/aspell/aspell_0.0.0.1.bb9
-rw-r--r--meta-selftest/recipes-test/aspell/aspell_0.60.8.bbappend (renamed from meta-selftest/recipes-test/aspell/aspell_0.60.6.1.bbappend)0
-rw-r--r--meta-selftest/recipes-test/container-image/container-image-testpkg.bb8
-rw-r--r--meta-selftest/recipes-test/container-image/container-test-image.bb8
-rw-r--r--meta-selftest/recipes-test/delay/delay.bb12
-rw-r--r--meta-selftest/recipes-test/devtool/devtool-test-local/file11
-rw-r--r--meta-selftest/recipes-test/devtool/devtool-test-local/file21
-rw-r--r--meta-selftest/recipes-test/devtool/devtool-test-local_6.03.bb15
-rw-r--r--meta-selftest/recipes-test/devtool/devtool-test-localonly.bb7
-rw-r--r--meta-selftest/recipes-test/devtool/devtool-test-localonly/file11
-rw-r--r--meta-selftest/recipes-test/devtool/devtool-test-localonly/file21
-rw-r--r--meta-selftest/recipes-test/devtool/devtool-test-patch-gz.bb18
-rw-r--r--meta-selftest/recipes-test/devtool/devtool-test-patch-gz/readme.patch.gzbin0 -> 449 bytes
-rw-r--r--meta-selftest/recipes-test/devtool/devtool-test-subdir.bb9
-rw-r--r--meta-selftest/recipes-test/devtool/devtool-test-subdir/devtool-test-subdir.tar.gzbin0 -> 181 bytes
-rw-r--r--meta-selftest/recipes-test/devtool/devtool-test-subdir/testfile1
-rw-r--r--meta-selftest/recipes-test/devtool/devtool-upgrade-test1-1.5.3/backported.patch37
-rw-r--r--meta-selftest/recipes-test/devtool/devtool-upgrade-test1_1.5.3.bb8
-rw-r--r--meta-selftest/recipes-test/devtool/devtool-upgrade-test1_1.5.3.bb.upgraded8
-rw-r--r--meta-selftest/recipes-test/devtool/devtool-upgrade-test2_git.bb4
-rw-r--r--meta-selftest/recipes-test/devtool/devtool-upgrade-test2_git.bb.upgraded4
-rw-r--r--meta-selftest/recipes-test/error/error.bb3
-rw-r--r--meta-selftest/recipes-test/fortran/files/hello.f955
-rw-r--r--meta-selftest/recipes-test/fortran/fortran-helloworld.bb24
-rw-r--r--meta-selftest/recipes-test/images/oe-selftest-image.bb2
-rw-r--r--meta-selftest/recipes-test/images/wic-image-minimal.bb9
-rw-r--r--meta-selftest/recipes-test/images/wic-image-minimal.wks8
-rw-r--r--meta-selftest/recipes-test/license/incompatible-license-alias.bb3
-rw-r--r--meta-selftest/recipes-test/license/incompatible-license.bb3
-rw-r--r--meta-selftest/recipes-test/license/incompatible-licenses.bb3
-rw-r--r--meta-selftest/recipes-test/license/incompatible-nonspdx-license.bb3
-rw-r--r--meta-selftest/recipes-test/m4/m4_%.bbappend (renamed from meta-selftest/recipes-test/m4/m4_1.4.17.bbappend)0
-rw-r--r--meta-selftest/recipes-test/man-db/files/0001-Test-patch-here.patch22
-rw-r--r--meta-selftest/recipes-test/man-db/man-db_%.bbappend (renamed from meta-selftest/recipes-test/man/man_1.6g.bbappend)0
-rw-r--r--meta-selftest/recipes-test/man/man/man-1.5h1-make.patch16
-rw-r--r--meta-selftest/recipes-test/multiconfig/multiconfig-image-packager_0.1.bb28
-rw-r--r--meta-selftest/recipes-test/multiconfig/multiconfig-test-parse.bb11
-rw-r--r--meta-selftest/recipes-test/postinst/postinst_1.0.bb72
-rw-r--r--meta-selftest/recipes-test/recipetool/selftest-recipetool-appendfile.bb2
-rw-r--r--meta-selftest/recipes-test/recipeutils/recipeutils-test.inc5
-rw-r--r--meta-selftest/recipes-test/recipeutils/recipeutils-test/anotherfile0
-rw-r--r--meta-selftest/recipes-test/recipeutils/recipeutils-test/somefile0
-rw-r--r--meta-selftest/recipes-test/recipeutils/recipeutils-test_1.2.bb13
-rw-r--r--meta-selftest/recipes-test/selftest-ed/selftest-ed_0.5.bb22
-rw-r--r--meta-selftest/recipes-test/selftest-ed/selftest-ed_1.14.1.bb36
-rw-r--r--meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink.bb30
-rwxr-xr-xmeta-selftest/recipes-test/selftest-hardlink/selftest-hardlink/gdb.sh8
-rw-r--r--meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink/hello.c5
-rw-r--r--meta-selftest/wic/test_biosplusefi_plugin.wks6
-rw-r--r--meta-selftest/wic/test_rawcopy_plugin.wks.in6
-rw-r--r--meta-selftest/wic/wictestdisk.wks7
66 files changed, 715 insertions, 107 deletions
diff --git a/meta-selftest/COPYING.MIT b/meta-selftest/COPYING.MIT
deleted file mode 100644
index 89de354795..0000000000
--- a/meta-selftest/COPYING.MIT
+++ /dev/null
@@ -1,17 +0,0 @@
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.
diff --git a/meta-selftest/conf/layer.conf b/meta-selftest/conf/layer.conf
index a847b78a20..08181a88cc 100644
--- a/meta-selftest/conf/layer.conf
+++ b/meta-selftest/conf/layer.conf
@@ -8,3 +8,5 @@ BBFILES += "${LAYERDIR}/recipes-*/*/*.bb \
BBFILE_COLLECTIONS += "selftest"
BBFILE_PATTERN_selftest = "^${LAYERDIR}/"
BBFILE_PRIORITY_selftest = "5"
+
+LAYERSERIES_COMPAT_selftest = "zeus"
diff --git a/meta-selftest/files/signing/key.passphrase b/meta-selftest/files/signing/key.passphrase
new file mode 100644
index 0000000000..5271a52680
--- /dev/null
+++ b/meta-selftest/files/signing/key.passphrase
@@ -0,0 +1 @@
+test123
diff --git a/meta-selftest/files/static-group b/meta-selftest/files/static-group
new file mode 100644
index 0000000000..9213b8e9bc
--- /dev/null
+++ b/meta-selftest/files/static-group
@@ -0,0 +1,14 @@
+messagebus:x:500:
+systemd-bus-proxy:x:501:
+systemd-network:x:502:
+systemd-resolve:x:503:
+systemd-timesync:x:504:
+polkitd:x:505:
+lock:x:506:
+systemd-journal:x:507:
+netdev:x:508:
+avahi:x:509:
+avahi-autoipd:x:510:
+rpc:x:511:
+rpcuser:x:513:
+
diff --git a/meta-selftest/files/static-passwd b/meta-selftest/files/static-passwd
new file mode 100644
index 0000000000..412f85d469
--- /dev/null
+++ b/meta-selftest/files/static-passwd
@@ -0,0 +1,11 @@
+messagebus:x:500:500::/var/lib/dbus:/bin/false
+systemd-bus-proxy:x:501:501::/:/bin/nologin
+systemd-network:x:502:502::/:/bin/nologin
+systemd-resolve:x:503:503::/:/bin/nologin
+systemd-timesync:x:504:504::/:/bin/nologin
+polkitd:x:505:505::/:/bin/nologin
+avahi:x:509:509::/:/bin/nologin
+avahi-autoipd:x:510:510::/:/bin/nologin
+rpc:x:511:511::/:/bin/nologin
+distcc:x:512:nogroup::/:/bin/nologin
+rpcuser:x:513:513::/var/lib/nfs:/bin/nologin
diff --git a/meta-selftest/lib/devtool/bbpath.py b/meta-selftest/lib/devtool/bbpath.py
new file mode 100644
index 0000000000..5e8ffb3af6
--- /dev/null
+++ b/meta-selftest/lib/devtool/bbpath.py
@@ -0,0 +1,44 @@
+import argparse
+
+already_loaded = False
+kept_context = None
+
+def plugin_name(filename):
+ return os.path.splitext(os.path.basename(filename))[0]
+
+def plugin_init(plugins):
+ global already_loaded
+ already_loaded = plugin_name(__file__) in (plugin_name(p.__name__) for p in plugins)
+
+def print_name(args, config, basepath, workspace):
+ print (__file__)
+
+def print_bbdir(args, config, basepath, workspace):
+ print (__file__.replace('/lib/devtool/bbpath.py',''))
+
+def print_registered(args, config, basepath, workspace):
+ global kept_context
+ print(kept_context.loaded)
+
+def multiloaded(args, config, basepath, workspace):
+ global already_loaded
+ print("yes" if already_loaded else "no")
+
+def register_commands(subparsers, context):
+ global kept_context
+ kept_context = context
+ if 'loaded' in context.__dict__:
+ context.loaded += 1
+ else:
+ context.loaded = 1
+
+ def addparser(name, helptxt, func):
+ parser = subparsers.add_parser(name, help=helptxt,
+ formatter_class=argparse.ArgumentDefaultsHelpFormatter)
+ parser.set_defaults(func=func)
+ return parser
+
+ addparser('pluginfile', 'Print the filename of this plugin', print_name)
+ addparser('bbdir', 'Print the BBPATH directory of this plugin', print_bbdir)
+ addparser('count', 'How many times have this plugin been registered.', print_registered)
+ addparser('multiloaded', 'How many times have this plugin been initialized', multiloaded)
diff --git a/meta-selftest/lib/oeqa/runtime/cases/dnf_runtime.py b/meta-selftest/lib/oeqa/runtime/cases/dnf_runtime.py
new file mode 100644
index 0000000000..64a3502370
--- /dev/null
+++ b/meta-selftest/lib/oeqa/runtime/cases/dnf_runtime.py
@@ -0,0 +1,50 @@
+from oeqa.core.decorator.depends import OETestDepends
+from oeqa.runtime.cases.dnf import DnfTest
+from oeqa.utils.httpserver import HTTPService
+from oeqa.core.decorator.data import skipIfDataVar
+
+class DnfSelftest(DnfTest):
+
+ @classmethod
+ def setUpClass(cls):
+ import tempfile
+ cls.temp_dir = tempfile.TemporaryDirectory(prefix="oeqa-remotefeeds-")
+ cls.repo_server = HTTPService(os.path.join(cls.tc.td['WORKDIR'], 'oe-rootfs-repo'),
+ cls.tc.target.server_ip)
+ cls.repo_server.start()
+
+ @classmethod
+ def tearDownClass(cls):
+ cls.repo_server.stop()
+ cls.temp_dir.cleanup()
+
+ @OETestDepends(['dnf.DnfBasicTest.test_dnf_help'])
+ @skipIfDataVar('PACKAGE_FEED_URIS', None,
+ 'Not suitable as PACKAGE_FEED_URIS is not set')
+ def test_verify_package_feeds(self):
+ """
+ Summary: Check correct setting of PACKAGE_FEED_URIS var
+ Expected: 1. Feeds were correctly set for dnf
+ 2. Update recovers packages from host's repo
+ Author: Humberto Ibarra <humberto.ibarra.lopez@intel.com>
+ Author: Alexander Kanavin <alex.kanavin@gmail.com>
+ """
+ # When we created an image, we had to supply fake ip and port
+ # for the feeds. Now we can patch the real ones into the config file.
+ temp_file = os.path.join(self.temp_dir.name, 'tmp.repo')
+ self.tc.target.copyFrom("/etc/yum.repos.d/oe-remote-repo.repo", temp_file)
+ fixed_config = open(temp_file, "r").read().replace("bogus_ip", self.tc.target.server_ip).replace("bogus_port", str(self.repo_server.port))
+ with open(temp_file, "w") as f:
+ f.write(fixed_config)
+ self.tc.target.copyTo(temp_file, "/etc/yum.repos.d/oe-remote-repo.repo")
+
+ import re
+ # Use '-y' for non-interactive mode: automatically import the feed signing key
+ output_makecache = self.dnf('-vy makecache')
+ self.assertTrue(re.match(r".*Failed to synchronize cache", output_makecache, re.DOTALL) is None, msg = "dnf makecache failed to synchronize repo: %s" %(output_makecache))
+ self.assertTrue(re.match(r".*Metadata cache created", output_makecache, re.DOTALL) is not None, msg = "dnf makecache failed: %s" %(output_makecache))
+
+ output_repoinfo = self.dnf('-v repoinfo')
+ matchobj = re.match(r".*Repo-pkgs\s*:\s*(?P<n_pkgs>[0-9]+)", output_repoinfo, re.DOTALL)
+ self.assertTrue(matchobj is not None, msg = "Could not find the amount of packages in dnf repoinfo output: %s" %(output_repoinfo))
+ self.assertTrue(int(matchobj.group('n_pkgs')) > 0, msg = "Amount of remote packages is not more than zero: %s\n" %(output_repoinfo))
diff --git a/meta-selftest/lib/oeqa/runtime/selftest.json b/meta-selftest/lib/oeqa/runtime/cases/selftest.json
index e5ae46ecd4..e5ae46ecd4 100644
--- a/meta-selftest/lib/oeqa/runtime/selftest.json
+++ b/meta-selftest/lib/oeqa/runtime/cases/selftest.json
diff --git a/meta-selftest/lib/oeqa/runtime/cases/selftest.py b/meta-selftest/lib/oeqa/runtime/cases/selftest.py
new file mode 100644
index 0000000000..19de740623
--- /dev/null
+++ b/meta-selftest/lib/oeqa/runtime/cases/selftest.py
@@ -0,0 +1,31 @@
+from oeqa.runtime.case import OERuntimeTestCase
+from oeqa.core.decorator.depends import OETestDepends
+
+class Selftest(OERuntimeTestCase):
+
+ @OETestDepends(['ssh.SSHTest.test_ssh'])
+ def test_install_package(self):
+ """
+ Summary: Check basic package installation functionality.
+ Expected: 1. Before the test socat must be installed using scp.
+ 2. After the test socat must be uninstalled using ssh.
+ This can't be checked in this test.
+ Product: oe-core
+ Author: Mariano Lopez <mariano.lopez@intel.com>
+ """
+
+ (status, output) = self.target.run("socat -V")
+ self.assertEqual(status, 0, msg="socat is not installed")
+
+ @OETestDepends(['selftest.Selftest.test_install_package'])
+ def test_verify_uninstall(self):
+ """
+ Summary: Check basic package installation functionality.
+ Expected: 1. test_install_package must uninstall socat.
+ This test is just to verify that.
+ Product: oe-core
+ Author: Mariano Lopez <mariano.lopez@intel.com>
+ """
+
+ (status, output) = self.target.run("socat -V")
+ self.assertNotEqual(status, 0, msg="socat is still installed")
diff --git a/meta-selftest/lib/oeqa/runtime/cases/virgl.py b/meta-selftest/lib/oeqa/runtime/cases/virgl.py
new file mode 100644
index 0000000000..c0abfd1b16
--- /dev/null
+++ b/meta-selftest/lib/oeqa/runtime/cases/virgl.py
@@ -0,0 +1,18 @@
+from oeqa.runtime.case import OERuntimeTestCase
+from oeqa.core.decorator.depends import OETestDepends
+import subprocess
+import oe.lsb
+
+class VirglTest(OERuntimeTestCase):
+
+ @OETestDepends(['ssh.SSHTest.test_ssh'])
+ def test_kernel_driver(self):
+ status, output = self.target.run('dmesg|grep virgl')
+ self.assertEqual(status, 0, "Checking for virgl driver in dmesg returned non-zero: %d\n%s" % (status, output))
+ self.assertIn("virgl 3d acceleration enabled", output, "virgl acceleration seems to be disabled:\n%s" %(output))
+
+ @OETestDepends(['virgl.VirglTest.test_kernel_driver'])
+ def test_kmscube(self):
+ status, output = self.target.run('kmscube', timeout=30)
+ self.assertEqual(status, 0, "kmscube exited with non-zero status %d and output:\n%s" %(status, output))
+ self.assertIn('renderer: "virgl"', output, "kmscube does not seem to use virgl:\n%s" %(output))
diff --git a/meta-selftest/lib/oeqa/runtime/selftest.py b/meta-selftest/lib/oeqa/runtime/selftest.py
deleted file mode 100644
index a7e58ab3d5..0000000000
--- a/meta-selftest/lib/oeqa/runtime/selftest.py
+++ /dev/null
@@ -1,55 +0,0 @@
-import os
-
-from oeqa.oetest import oeRuntimeTest, skipModule
-from oeqa.utils.commands import runCmd
-from oeqa.utils.decorators import *
-
-class Selftest(oeRuntimeTest):
-
- @skipUnlessPassed("test_ssh")
- @tag("selftest_package_install")
- def test_install_package(self):
- """
- Summary: Check basic package installation functionality.
- Expected: 1. Before the test socat must be installed using scp.
- 2. After the test socat must be unistalled using ssh.
- This can't be checked in this test.
- Product: oe-core
- Author: Mariano Lopez <mariano.lopez@intel.com>
- """
-
- (status, output) = self.target.run("socat -V")
- self.assertEqual(status, 0, msg="socat is not installed")
-
- @skipUnlessPassed("test_install_package")
- @tag("selftest_package_install")
- def test_verify_unistall(self):
- """
- Summary: Check basic package installation functionality.
- Expected: 1. test_install_package must unistall socat.
- This test is just to verify that.
- Product: oe-core
- Author: Mariano Lopez <mariano.lopez@intel.com>
- """
-
- (status, output) = self.target.run("socat -V")
- self.assertNotEqual(status, 0, msg="socat is still installed")
-
- @tag("selftest_sdk")
- def test_sdk(self):
-
- result = runCmd("env -0")
- sdk_path = search_sdk_path(result.output)
- self.assertTrue(sdk_path, msg="Can't find SDK path")
-
- tar_cmd = os.path.join(sdk_path, "tar")
- result = runCmd("%s --help" % tar_cmd)
-
-def search_sdk_path(env):
- for line in env.split("\0"):
- (key, _, value) = line.partition("=")
- if key == "PATH":
- for path in value.split(":"):
- if "pokysdk" in path:
- return path
- return ""
diff --git a/meta-selftest/lib/oeqa/selftest/cases/external-layer.py b/meta-selftest/lib/oeqa/selftest/cases/external-layer.py
new file mode 100644
index 0000000000..59b1afab7d
--- /dev/null
+++ b/meta-selftest/lib/oeqa/selftest/cases/external-layer.py
@@ -0,0 +1,16 @@
+#from oeqa.selftest.base import oeSelfTest
+from oeqa.selftest.case import OESelftestTestCase
+#from oeqa.utils.decorators import testcase
+
+
+class ImportedTests(OESelftestTestCase):
+
+ def test_unconditional_pass(self):
+ """
+ Summary: Doesn't check anything, used to check import test from other layers.
+ Expected: 1. Pass unconditionally
+ Product: oe-core
+ Author: Mariano Lopez <mariano.lopez@intel.com
+ """
+
+ self.assertEqual(True, True, msg = "Impossible to fail this test")
diff --git a/meta-selftest/lib/recipetool/bbpath.py b/meta-selftest/lib/recipetool/bbpath.py
new file mode 100644
index 0000000000..783b2dc769
--- /dev/null
+++ b/meta-selftest/lib/recipetool/bbpath.py
@@ -0,0 +1,41 @@
+import argparse
+
+already_loaded = False
+register_count = 0
+
+def plugin_name(filename):
+ return os.path.splitext(os.path.basename(filename))[0]
+
+def plugin_init(plugins):
+ global already_loaded
+ already_loaded = plugin_name(__file__) in (plugin_name(p.__name__) for p in plugins)
+
+def print_name(opts):
+ print (__file__)
+
+def print_bbdir(opts):
+ print (__file__.replace('/lib/recipetool/bbpath.py',''))
+
+def print_registered(opts):
+ #global kept_context
+ #print(kept_context.loaded)
+ print ("1")
+
+def multiloaded(opts):
+ global already_loaded
+ print("yes" if already_loaded else "no")
+
+def register_commands(subparsers):
+ global register_count
+ register_count += 1
+
+ def addparser(name, helptxt, func):
+ parser = subparsers.add_parser(name, help=helptxt,
+ formatter_class=argparse.ArgumentDefaultsHelpFormatter)
+ parser.set_defaults(func=func)
+ return parser
+
+ addparser('pluginfile', 'Print the filename of this plugin', print_name)
+ addparser('bbdir', 'Print the BBPATH directory of this plugin', print_bbdir)
+ addparser('count', 'How many times have this plugin been registered.', print_registered)
+ addparser('multiloaded', 'How many times have this plugin been initialized', multiloaded)
diff --git a/meta-selftest/recipes-devtools/python/python-async-test.inc b/meta-selftest/recipes-devtools/python/python-async-test.inc
new file mode 100644
index 0000000000..c9602e8e52
--- /dev/null
+++ b/meta-selftest/recipes-devtools/python/python-async-test.inc
@@ -0,0 +1,16 @@
+SUMMARY = "Python framework to process interdependent tasks in a pool of workers"
+HOMEPAGE = "http://github.com/gitpython-developers/async"
+SECTION = "devel/python"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://PKG-INFO;beginline=8;endline=8;md5=88df8e78b9edfd744953862179f2d14e"
+
+inherit pypi
+
+PYPI_PACKAGE = "async"
+
+SRC_URI[md5sum] = "9b06b5997de2154f3bc0273f80bcef6b"
+SRC_URI[sha256sum] = "ac6894d876e45878faae493b0cf61d0e28ec417334448ac0a6ea2229d8343051"
+
+RDEPENDS_${PN} += "${PYTHON_PN}-threading"
+
+BBCLASSEXTEND = "nativesdk"
diff --git a/meta-selftest/recipes-devtools/python/python3-async-test_0.6.2.bb b/meta-selftest/recipes-devtools/python/python3-async-test_0.6.2.bb
new file mode 100644
index 0000000000..22e241afb3
--- /dev/null
+++ b/meta-selftest/recipes-devtools/python/python3-async-test_0.6.2.bb
@@ -0,0 +1,2 @@
+inherit setuptools3
+require python-async-test.inc
diff --git a/meta-selftest/recipes-test/aspell/aspell_0.0.0.1.bb b/meta-selftest/recipes-test/aspell/aspell_0.0.0.1.bb
index 20a0ab7d39..9f905a5198 100644
--- a/meta-selftest/recipes-test/aspell/aspell_0.0.0.1.bb
+++ b/meta-selftest/recipes-test/aspell/aspell_0.0.0.1.bb
@@ -8,12 +8,12 @@ SECTION = "console/utils"
LICENSE = "LGPLv2 | LGPLv2.1"
LIC_FILES_CHKSUM = "file://COPYING;md5=7fbc338309ac38fefcd64b04bb903e34"
-PR = "r1"
-
SRC_URI = "${GNU_MIRROR}/aspell/aspell-${PV}.tar.gz"
SRC_URI[md5sum] = "e66a9c9af6a60dc46134fdacf6ce97d7"
SRC_URI[sha256sum] = "f52583a83a63633701c5f71db3dc40aab87b7f76b29723aeb27941eff42df6e1"
+EXCLUDE_FROM_WORLD = "1"
+
PACKAGECONFIG ??= ""
PACKAGECONFIG[curses] = "--enable-curses,--disable-curses,ncurses"
@@ -26,5 +26,8 @@ FILES_${PN} = "${bindir}/aspell"
FILES_libpspell = "${libdir}/libpspell.so.*"
FILES_libpspell-dev = "${libdir}/libpspell* ${bindir}/pspell-config ${includedir}/pspell"
-ARM_INSTRUCTION_SET = "arm"
+ARM_INSTRUCTION_SET_armv4 = "arm"
+ARM_INSTRUCTION_SET_armv5 = "arm"
+ARM_INSTRUCTION_SET_armv6 = "arm"
+
inherit autotools gettext
diff --git a/meta-selftest/recipes-test/aspell/aspell_0.60.6.1.bbappend b/meta-selftest/recipes-test/aspell/aspell_0.60.8.bbappend
index 205720982c..205720982c 100644
--- a/meta-selftest/recipes-test/aspell/aspell_0.60.6.1.bbappend
+++ b/meta-selftest/recipes-test/aspell/aspell_0.60.8.bbappend
diff --git a/meta-selftest/recipes-test/container-image/container-image-testpkg.bb b/meta-selftest/recipes-test/container-image/container-image-testpkg.bb
new file mode 100644
index 0000000000..f8dd2290b3
--- /dev/null
+++ b/meta-selftest/recipes-test/container-image/container-image-testpkg.bb
@@ -0,0 +1,8 @@
+LICENSE = "MIT"
+
+INHIBIT_DEFAULT_DEPS = "1"
+
+do_install_append() {
+ install -d ${D}${bindir}
+ touch ${D}${bindir}/theapp
+}
diff --git a/meta-selftest/recipes-test/container-image/container-test-image.bb b/meta-selftest/recipes-test/container-image/container-test-image.bb
new file mode 100644
index 0000000000..d5f939c6e9
--- /dev/null
+++ b/meta-selftest/recipes-test/container-image/container-test-image.bb
@@ -0,0 +1,8 @@
+IMAGE_INSTALL += "container-image-testpkg"
+
+LICENSE = "MIT"
+
+IMAGE_FSTYPES = "container"
+IMAGE_LINGUAS = ""
+
+inherit core-image
diff --git a/meta-selftest/recipes-test/delay/delay.bb b/meta-selftest/recipes-test/delay/delay.bb
new file mode 100644
index 0000000000..f92d3d99e2
--- /dev/null
+++ b/meta-selftest/recipes-test/delay/delay.bb
@@ -0,0 +1,12 @@
+SUMMARY = "Recipe with a fixed delay task"
+DESCRIPTION = "Contains a delay task to be used to for testing."
+LICENSE = "MIT"
+
+INHIBIT_DEFAULT_DEPS = "1"
+EXCLUDE_FROM_WORLD = "1"
+
+do_delay() {
+ sleep 5
+}
+do_delay[nostamp] = "1"
+addtask delay \ No newline at end of file
diff --git a/meta-selftest/recipes-test/devtool/devtool-test-local/file1 b/meta-selftest/recipes-test/devtool/devtool-test-local/file1
new file mode 100644
index 0000000000..f4bdcfc831
--- /dev/null
+++ b/meta-selftest/recipes-test/devtool/devtool-test-local/file1
@@ -0,0 +1 @@
+The first file
diff --git a/meta-selftest/recipes-test/devtool/devtool-test-local/file2 b/meta-selftest/recipes-test/devtool/devtool-test-local/file2
new file mode 100644
index 0000000000..a7e2414bd5
--- /dev/null
+++ b/meta-selftest/recipes-test/devtool/devtool-test-local/file2
@@ -0,0 +1 @@
+The second file
diff --git a/meta-selftest/recipes-test/devtool/devtool-test-local_6.03.bb b/meta-selftest/recipes-test/devtool/devtool-test-local_6.03.bb
new file mode 100644
index 0000000000..6bfc557060
--- /dev/null
+++ b/meta-selftest/recipes-test/devtool/devtool-test-local_6.03.bb
@@ -0,0 +1,15 @@
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3"
+
+INHIBIT_DEFAULT_DEPS = "1"
+
+SRC_URI = "http://downloads.yoctoproject.org/mirror/sources/syslinux-${PV}.tar.xz \
+ file://file1 \
+ file://file2"
+
+SRC_URI[md5sum] = "92a253df9211e9c20172796ecf388f13"
+SRC_URI[sha256sum] = "26d3986d2bea109d5dc0e4f8c4822a459276cf021125e8c9f23c3cca5d8c850e"
+
+S = "${WORKDIR}/syslinux-${PV}"
+
+EXCLUDE_FROM_WORLD = "1"
diff --git a/meta-selftest/recipes-test/devtool/devtool-test-localonly.bb b/meta-selftest/recipes-test/devtool/devtool-test-localonly.bb
new file mode 100644
index 0000000000..3f7123cda0
--- /dev/null
+++ b/meta-selftest/recipes-test/devtool/devtool-test-localonly.bb
@@ -0,0 +1,7 @@
+LICENSE = "CLOSED"
+INHIBIT_DEFAULT_DEPS = "1"
+
+SRC_URI = "file://file1 \
+ file://file2"
+
+EXCLUDE_FROM_WORLD = "1"
diff --git a/meta-selftest/recipes-test/devtool/devtool-test-localonly/file1 b/meta-selftest/recipes-test/devtool/devtool-test-localonly/file1
new file mode 100644
index 0000000000..f4bdcfc831
--- /dev/null
+++ b/meta-selftest/recipes-test/devtool/devtool-test-localonly/file1
@@ -0,0 +1 @@
+The first file
diff --git a/meta-selftest/recipes-test/devtool/devtool-test-localonly/file2 b/meta-selftest/recipes-test/devtool/devtool-test-localonly/file2
new file mode 100644
index 0000000000..a7e2414bd5
--- /dev/null
+++ b/meta-selftest/recipes-test/devtool/devtool-test-localonly/file2
@@ -0,0 +1 @@
+The second file
diff --git a/meta-selftest/recipes-test/devtool/devtool-test-patch-gz.bb b/meta-selftest/recipes-test/devtool/devtool-test-patch-gz.bb
new file mode 100644
index 0000000000..fc3799590c
--- /dev/null
+++ b/meta-selftest/recipes-test/devtool/devtool-test-patch-gz.bb
@@ -0,0 +1,18 @@
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
+
+DEPENDS = "libxres libxext virtual/libx11 ncurses"
+
+SRC_URI = "http://downloads.yoctoproject.org/releases/xrestop/xrestop-0.4.tar.gz \
+ file://readme.patch.gz \
+ "
+UPSTREAM_VERSION_UNKNOWN = "1"
+
+S = "${WORKDIR}/xrestop-0.4"
+
+SRC_URI[md5sum] = "d8a54596cbaf037e62b80c4585a3ca9b"
+SRC_URI[sha256sum] = "67c2fc94a7ecedbaae0d1837e82e93d1d98f4a6d759828860e552119af3ce257"
+
+inherit autotools pkgconfig
+
+EXCLUDE_FROM_WORLD = "1"
diff --git a/meta-selftest/recipes-test/devtool/devtool-test-patch-gz/readme.patch.gz b/meta-selftest/recipes-test/devtool/devtool-test-patch-gz/readme.patch.gz
new file mode 100644
index 0000000000..4752492ccd
--- /dev/null
+++ b/meta-selftest/recipes-test/devtool/devtool-test-patch-gz/readme.patch.gz
Binary files differ
diff --git a/meta-selftest/recipes-test/devtool/devtool-test-subdir.bb b/meta-selftest/recipes-test/devtool/devtool-test-subdir.bb
new file mode 100644
index 0000000000..3f6956524b
--- /dev/null
+++ b/meta-selftest/recipes-test/devtool/devtool-test-subdir.bb
@@ -0,0 +1,9 @@
+LICENSE = "CLOSED"
+INHIBIT_DEFAULT_DEPS = "1"
+
+SRC_URI = "file://devtool-test-subdir.tar.gz \
+ file://testfile;subdir=${BPN}"
+
+S = "${WORKDIR}/${BPN}"
+
+EXCLUDE_FROM_WORLD = "1"
diff --git a/meta-selftest/recipes-test/devtool/devtool-test-subdir/devtool-test-subdir.tar.gz b/meta-selftest/recipes-test/devtool/devtool-test-subdir/devtool-test-subdir.tar.gz
new file mode 100644
index 0000000000..3d44f803cb
--- /dev/null
+++ b/meta-selftest/recipes-test/devtool/devtool-test-subdir/devtool-test-subdir.tar.gz
Binary files differ
diff --git a/meta-selftest/recipes-test/devtool/devtool-test-subdir/testfile b/meta-selftest/recipes-test/devtool/devtool-test-subdir/testfile
new file mode 100644
index 0000000000..12b519c0d6
--- /dev/null
+++ b/meta-selftest/recipes-test/devtool/devtool-test-subdir/testfile
@@ -0,0 +1 @@
+Modified version
diff --git a/meta-selftest/recipes-test/devtool/devtool-upgrade-test1-1.5.3/backported.patch b/meta-selftest/recipes-test/devtool/devtool-upgrade-test1-1.5.3/backported.patch
new file mode 100644
index 0000000000..c4f3f12666
--- /dev/null
+++ b/meta-selftest/recipes-test/devtool/devtool-upgrade-test1-1.5.3/backported.patch
@@ -0,0 +1,37 @@
+commit ced2ec32b657a7f52604b2e16e5d5881041c517a
+Author: OpenEmbedded <oe.patch@oe>
+Date: Mon Nov 18 18:43:15 2019 +0100
+
+ Backport of the NEWS file from version 1.6.0
+
+diff --git a/doc/NEWS b/doc/NEWS
+index 69793fc..fd49b1c 100644
+--- a/doc/NEWS
++++ b/doc/NEWS
+@@ -1,3 +1,26 @@
++1.6.0 - 15 March 2015
++ - fix lstat64 support when unavailable - separate patches supplied by
++ Ganael Laplanche and Peter Korsgaard
++ - (#1506) new option "-D" / "--delay-start" to only show bar after N
++ seconds (Damon Harper)
++ - new option "--fineta" / "-I" to show ETA as time of day rather than time
++ remaining - patch supplied by Erkki Seppälä (r147)
++ - (#1509) change ETA (--eta / -e) so that days are given if the hours
++ remaining are 24 or more (Jacek Wielemborek)
++ - (#1499) repeat read and write attempts on partial buffer fill/empty to
++ work around post-signal transfer rate drop reported by Ralf Ramsauer
++ - (#1507) do not try to calculate total size in line mode, due to bug
++ reported by Jacek Wielemborek and Michiel Van Herwegen
++ - cleanup: removed defunct RATS comments and unnecessary copyright notices
++ - clean up displayed lines when using --watchfd PID, when PID exits
++ - output errors on a new line to avoid overwriting transfer bar
++
++1.5.7 - 26 August 2014
++ - show KiB instead of incorrect kiB (Debian bug #706175)
++ - (#1284) do not gzip man page, for non-Linux OSes (Bob Friesenhahn)
++ - work around "awk" bug in tests/016-numeric-timer in decimal "," locales
++ - fix "make rpm" and "make srpm", extend "make release" to sign releases
++
+ 1.5.3 - 4 May 2014
+ - remove SPLICE_F_NONBLOCK to fix problem with slow splice() (Jan Seda)
+
diff --git a/meta-selftest/recipes-test/devtool/devtool-upgrade-test1_1.5.3.bb b/meta-selftest/recipes-test/devtool/devtool-upgrade-test1_1.5.3.bb
index e93b0d5514..fee5bee739 100644
--- a/meta-selftest/recipes-test/devtool/devtool-upgrade-test1_1.5.3.bb
+++ b/meta-selftest/recipes-test/devtool/devtool-upgrade-test1_1.5.3.bb
@@ -3,7 +3,11 @@ LICENSE = "Artistic-2.0"
LIC_FILES_CHKSUM = "file://doc/COPYING;md5=9c50db2589ee3ef10a9b7b2e50ce1d02"
SRC_URI = "http://www.ivarch.com/programs/sources/pv-${PV}.tar.gz \
- file://0001-Add-a-note-line-to-the-quick-reference.patch"
+ file://0001-Add-a-note-line-to-the-quick-reference.patch \
+ file://backported.patch \
+ "
+UPSTREAM_CHECK_URI = "http://www.ivarch.com/programs/pv.shtml"
+RECIPE_NO_UPDATE_REASON = "This recipe is used to test devtool upgrade feature"
SRC_URI[md5sum] = "9365d86bd884222b4bf1039b5a9ed1bd"
SRC_URI[sha256sum] = "681bcca9784bf3cb2207e68236d1f68e2aa7b80f999b5750dc77dcd756e81fbc"
@@ -12,5 +16,7 @@ PR = "r5"
S = "${WORKDIR}/pv-${PV}"
+EXCLUDE_FROM_WORLD = "1"
+
inherit autotools
diff --git a/meta-selftest/recipes-test/devtool/devtool-upgrade-test1_1.5.3.bb.upgraded b/meta-selftest/recipes-test/devtool/devtool-upgrade-test1_1.5.3.bb.upgraded
index afcc4aa13c..66e45c7e84 100644
--- a/meta-selftest/recipes-test/devtool/devtool-upgrade-test1_1.5.3.bb.upgraded
+++ b/meta-selftest/recipes-test/devtool/devtool-upgrade-test1_1.5.3.bb.upgraded
@@ -3,12 +3,18 @@ LICENSE = "Artistic-2.0"
LIC_FILES_CHKSUM = "file://doc/COPYING;md5=9c50db2589ee3ef10a9b7b2e50ce1d02"
SRC_URI = "http://www.ivarch.com/programs/sources/pv-${PV}.tar.gz \
- file://0001-Add-a-note-line-to-the-quick-reference.patch"
+ file://0001-Add-a-note-line-to-the-quick-reference.patch \
+ file://backported.patch \
+ "
+UPSTREAM_CHECK_URI = "http://www.ivarch.com/programs/pv.shtml"
+RECIPE_NO_UPDATE_REASON = "This recipe is used to test devtool upgrade feature"
SRC_URI[md5sum] = "062bca5ff33df1dd09472e7fc3bbe332"
SRC_URI[sha256sum] = "9dd45391806b0ed215abee4c5ac1597d018c386fe9c1f5afd2f6bc3b07fd82c3"
S = "${WORKDIR}/pv-${PV}"
+EXCLUDE_FROM_WORLD = "1"
+
inherit autotools
diff --git a/meta-selftest/recipes-test/devtool/devtool-upgrade-test2_git.bb b/meta-selftest/recipes-test/devtool/devtool-upgrade-test2_git.bb
index 9bfce0afee..07b83276fb 100644
--- a/meta-selftest/recipes-test/devtool/devtool-upgrade-test2_git.bb
+++ b/meta-selftest/recipes-test/devtool/devtool-upgrade-test2_git.bb
@@ -12,7 +12,11 @@ PV = "0.1+git${SRCPV}"
PR = "r2"
SRC_URI = "git://git.yoctoproject.org/dbus-wait"
+UPSTREAM_CHECK_COMMITS = "1"
+RECIPE_NO_UPDATE_REASON = "This recipe is used to test devtool upgrade feature"
S = "${WORKDIR}/git"
+EXCLUDE_FROM_WORLD = "1"
+
inherit autotools pkgconfig
diff --git a/meta-selftest/recipes-test/devtool/devtool-upgrade-test2_git.bb.upgraded b/meta-selftest/recipes-test/devtool/devtool-upgrade-test2_git.bb.upgraded
index 9b947ed9ea..32ec4b14fa 100644
--- a/meta-selftest/recipes-test/devtool/devtool-upgrade-test2_git.bb.upgraded
+++ b/meta-selftest/recipes-test/devtool/devtool-upgrade-test2_git.bb.upgraded
@@ -11,7 +11,11 @@ SRCREV = "6cc6077a36fe2648a5f993fe7c16c9632f946517"
PV = "0.1+git${SRCPV}"
SRC_URI = "git://git.yoctoproject.org/dbus-wait"
+UPSTREAM_CHECK_COMMITS = "1"
+RECIPE_NO_UPDATE_REASON = "This recipe is used to test devtool upgrade feature"
S = "${WORKDIR}/git"
+EXCLUDE_FROM_WORLD = "1"
+
inherit autotools pkgconfig
diff --git a/meta-selftest/recipes-test/error/error.bb b/meta-selftest/recipes-test/error/error.bb
index a7bdecf29d..65d00a46d9 100644
--- a/meta-selftest/recipes-test/error/error.bb
+++ b/meta-selftest/recipes-test/error/error.bb
@@ -1,9 +1,8 @@
SUMMARY = "Error Test case that fails on do_compile"
DESCRIPTION = "This generates a compile time error to be used to for testing."
LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
-INHIBIT_DEFAULT_DEPS = "1"
+INHIBIT_DEFAULT_DEPS = "1"
EXCLUDE_FROM_WORLD = "1"
do_compile() {
diff --git a/meta-selftest/recipes-test/fortran/files/hello.f95 b/meta-selftest/recipes-test/fortran/files/hello.f95
new file mode 100644
index 0000000000..a0745fc64d
--- /dev/null
+++ b/meta-selftest/recipes-test/fortran/files/hello.f95
@@ -0,0 +1,5 @@
+program helloworld
+
+ print * , "Hello World!"
+
+end program helloworld
diff --git a/meta-selftest/recipes-test/fortran/fortran-helloworld.bb b/meta-selftest/recipes-test/fortran/fortran-helloworld.bb
new file mode 100644
index 0000000000..3a46404477
--- /dev/null
+++ b/meta-selftest/recipes-test/fortran/fortran-helloworld.bb
@@ -0,0 +1,24 @@
+SUMMARY = "Fortran Hello World"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
+
+DEPENDS = "libgfortran"
+
+SRC_URI = "file://hello.f95"
+
+# These set flags that Fortran doesn't support
+SECURITY_CFLAGS = ""
+SECURITY_LDFLAGS = ""
+
+do_compile() {
+ ${FC} ${LDFLAGS} ${WORKDIR}/hello.f95 -o ${B}/fortran-hello
+}
+
+do_install() {
+ install -D ${B}/fortran-hello ${D}${bindir}/fortran-hello
+}
+
+python () {
+ if not d.getVar("FORTRAN"):
+ raise bb.parse.SkipRecipe("Fortran isn't enabled")
+}
diff --git a/meta-selftest/recipes-test/images/oe-selftest-image.bb b/meta-selftest/recipes-test/images/oe-selftest-image.bb
index f17094c5d0..5d4d10eef6 100644
--- a/meta-selftest/recipes-test/images/oe-selftest-image.bb
+++ b/meta-selftest/recipes-test/images/oe-selftest-image.bb
@@ -1,6 +1,6 @@
SUMMARY = "An image used during oe-selftest tests"
-IMAGE_INSTALL = "packagegroup-core-boot ${ROOTFS_PKGMANAGE_BOOTSTRAP} dropbear"
+IMAGE_INSTALL = "packagegroup-core-boot dropbear"
IMAGE_FEATURES = "debug-tweaks"
IMAGE_LINGUAS = " "
diff --git a/meta-selftest/recipes-test/images/wic-image-minimal.bb b/meta-selftest/recipes-test/images/wic-image-minimal.bb
index 58bf5a553c..e1da203b59 100644
--- a/meta-selftest/recipes-test/images/wic-image-minimal.bb
+++ b/meta-selftest/recipes-test/images/wic-image-minimal.bb
@@ -2,19 +2,14 @@ SUMMARY = "An example of partitioned image."
SRC_URI = "file://${FILE_DIRNAME}/${BPN}.wks"
-IMAGE_INSTALL = "packagegroup-core-boot ${ROOTFS_PKGMANAGE_BOOTSTRAP}"
+IMAGE_INSTALL = "packagegroup-core-boot"
IMAGE_FSTYPES = "wic"
-RM_OLD_IMAGE = "1"
-DEPENDS = "syslinux syslinux-native dosfstools-native mtools-native gptfdisk-native"
+WKS_FILE_DEPENDS = "syslinux syslinux-native dosfstools-native mtools-native gptfdisk-native"
LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
-# core-image-minimal is referenced in .wks, so we need its rootfs
-# to be ready before our rootfs
-do_rootfs[depends] += "core-image-minimal:do_image core-image-minimal:do_rootfs_wicenv"
-
IMAGE_ROOTFS_EXTRA_SPACE = "2000"
inherit image
diff --git a/meta-selftest/recipes-test/images/wic-image-minimal.wks b/meta-selftest/recipes-test/images/wic-image-minimal.wks
index d55075d503..ae69cb6e3c 100644
--- a/meta-selftest/recipes-test/images/wic-image-minimal.wks
+++ b/meta-selftest/recipes-test/images/wic-image-minimal.wks
@@ -2,9 +2,9 @@
# long-description: This image contains boot partition and 3 rootfs partitions
# created from core-image-minimal and wic-image-minimal image recipes.
-part /boot --source bootimg-pcbios --ondisk vda --label boot --active --align 1024
-part / --source rootfs --ondisk vda --fstype=ext4 --label platform --align 1024 --use-uuid
-part /mnt --source rootfs --rootfs-dir=core-image-minimal --ondisk vda --fstype=ext4 --label core --align 1024
-part backup --source rootfs --rootfs-dir=wic-image-minimal --ondisk vda --fstype=ext4 --label backup --align 1024
+part /boot --source bootimg-pcbios --ondisk sda --label boot --active --align 1024
+part / --source rootfs --ondisk sda --fstype=ext4 --label platform --align 1024 --use-uuid
+part /media --source rootfs --rootfs-dir=wic-image-minimal --ondisk sda --fstype=ext4 --label uuid-test --align 1024 --use-uuid --fsuuid 2c71ef06-a81d-4735-9d3a-379b69c6bdba
+part /mnt --source rootfs --rootfs-dir=wic-image-minimal --ondisk sda --fstype=ext4 --label core --align 1024
bootloader --ptable gpt --timeout=0 --append="rootwait console=tty0"
diff --git a/meta-selftest/recipes-test/license/incompatible-license-alias.bb b/meta-selftest/recipes-test/license/incompatible-license-alias.bb
new file mode 100644
index 0000000000..e0b4e13c26
--- /dev/null
+++ b/meta-selftest/recipes-test/license/incompatible-license-alias.bb
@@ -0,0 +1,3 @@
+SUMMARY = "Recipe with an alias of an SPDX license"
+DESCRIPTION = "Is licensed with an alias of an SPDX license to be used for testing"
+LICENSE = "GPLv3"
diff --git a/meta-selftest/recipes-test/license/incompatible-license.bb b/meta-selftest/recipes-test/license/incompatible-license.bb
new file mode 100644
index 0000000000..1728ad76b7
--- /dev/null
+++ b/meta-selftest/recipes-test/license/incompatible-license.bb
@@ -0,0 +1,3 @@
+SUMMARY = "Recipe with an SPDX license"
+DESCRIPTION = "Is licensed with an SPDX license to be used for testing"
+LICENSE = "GPL-3.0"
diff --git a/meta-selftest/recipes-test/license/incompatible-licenses.bb b/meta-selftest/recipes-test/license/incompatible-licenses.bb
new file mode 100644
index 0000000000..9c1545efba
--- /dev/null
+++ b/meta-selftest/recipes-test/license/incompatible-licenses.bb
@@ -0,0 +1,3 @@
+SUMMARY = "Recipe with multiple SPDX licenses"
+DESCRIPTION = "Is licensed with multiple SPDX licenses to be used for testing"
+LICENSE = "GPL-2.0 & GPL-3.0 & LGPL-3.0"
diff --git a/meta-selftest/recipes-test/license/incompatible-nonspdx-license.bb b/meta-selftest/recipes-test/license/incompatible-nonspdx-license.bb
new file mode 100644
index 0000000000..35af0966ef
--- /dev/null
+++ b/meta-selftest/recipes-test/license/incompatible-nonspdx-license.bb
@@ -0,0 +1,3 @@
+SUMMARY = "Recipe with a non-SPDX license"
+DESCRIPTION = "Is licensed with a non-SPDX license to be used for testing"
+LICENSE = "FooLicense"
diff --git a/meta-selftest/recipes-test/m4/m4_1.4.17.bbappend b/meta-selftest/recipes-test/m4/m4_%.bbappend
index 205720982c..205720982c 100644
--- a/meta-selftest/recipes-test/m4/m4_1.4.17.bbappend
+++ b/meta-selftest/recipes-test/m4/m4_%.bbappend
diff --git a/meta-selftest/recipes-test/man-db/files/0001-Test-patch-here.patch b/meta-selftest/recipes-test/man-db/files/0001-Test-patch-here.patch
new file mode 100644
index 0000000000..b1d5eab2b8
--- /dev/null
+++ b/meta-selftest/recipes-test/man-db/files/0001-Test-patch-here.patch
@@ -0,0 +1,22 @@
+From efc8831f33106e6b48de8e612c2d816fe7d1ae68 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Fri, 9 Feb 2018 17:37:48 +0200
+Subject: [PATCH] Test patch here!
+
+This is an invalid patch used by oe-selftest
+---
+ README | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/README b/README
+index 48fff57..26d1234 100644
+--- a/README
++++ b/README
+@@ -1,3 +1,4 @@
++This is a test patch for purposes of oe-selftest
+ THIS LINE MAKES THIS PATCH INVALID README for the man-db manual pager suite
+ ========================================
+
+--
+2.15.1
+
diff --git a/meta-selftest/recipes-test/man/man_1.6g.bbappend b/meta-selftest/recipes-test/man-db/man-db_%.bbappend
index 205720982c..205720982c 100644
--- a/meta-selftest/recipes-test/man/man_1.6g.bbappend
+++ b/meta-selftest/recipes-test/man-db/man-db_%.bbappend
diff --git a/meta-selftest/recipes-test/man/man/man-1.5h1-make.patch b/meta-selftest/recipes-test/man/man/man-1.5h1-make.patch
deleted file mode 100644
index a0d59b78ce..0000000000
--- a/meta-selftest/recipes-test/man/man/man-1.5h1-make.patch
+++ /dev/null
@@ -1,16 +0,0 @@
-Test patch here!
-This is invalid patch used by tests in scripts/lib/selftests.
-
---- man-1.5g/man/Makefile.in.mike Fri Apr 9 13:35:54 1999
-+++ man-1.5g/man/Makefile.in Fri Apr 9 13:36:45 1999
-@@ -1,8 +1,8 @@
- #MAKE THIS PATCH INVALID
- MAN1 = man whatis apropos
--MAN5 = man.conf
-+MAN5 = man.config
- MAN8 = makewhatis
--ALL = man.1 whatis.1 apropos.1 man.conf.5
-+ALL = man.1 whatis.1 apropos.1 man.config.5
- MAYBE8 = makewhatis
-
- .SUFFIXES: .man .1 .5 .8
diff --git a/meta-selftest/recipes-test/multiconfig/multiconfig-image-packager_0.1.bb b/meta-selftest/recipes-test/multiconfig/multiconfig-image-packager_0.1.bb
new file mode 100644
index 0000000000..a76a6bea1b
--- /dev/null
+++ b/meta-selftest/recipes-test/multiconfig/multiconfig-image-packager_0.1.bb
@@ -0,0 +1,28 @@
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
+
+MCMACHINE_virtclass-mcextend-musl = "qemux86-64"
+MCMACHINE_virtclass-mcextend-tiny = "qemux86"
+MCIMGTYPE_virtclass-mcextend-musl = "ext4"
+MCIMGTYPE_virtclass-mcextend-tiny = "cpio.gz"
+
+MC_DEPLOY_DIR_IMAGE = "${TOPDIR}/tmp-mc-${MCNAME}/deploy/images/${MCMACHINE}"
+
+do_install[mcdepends] += "mc::${MCNAME}:core-image-minimal:do_image_complete mc::${MCNAME}:virtual/kernel:do_deploy"
+
+do_install () {
+ install -d ${D}/var/lib/machines/${MCNAME}
+ install ${MC_DEPLOY_DIR_IMAGE}/core-image-minimal-${MCMACHINE}.${MCIMGTYPE} ${D}/var/lib/machines/${MCNAME}/core-image-minimal.${MCIMGTYPE}
+ install ${MC_DEPLOY_DIR_IMAGE}/bzImage ${D}/var/lib/machines/${MCNAME}
+}
+
+python () {
+ mcname = d.getVar('MCNAME')
+ if not mcname:
+ raise bb.parse.SkipRecipe("Not a multiconfig target")
+ multiconfigs = d.getVar('BBMULTICONFIG') or ""
+ if mcname not in multiconfigs:
+ raise bb.parse.SkipRecipe("multiconfig target %s not enabled" % mcname)
+}
+
+BBCLASSEXTEND = "mcextend:tiny mcextend:musl"
diff --git a/meta-selftest/recipes-test/multiconfig/multiconfig-test-parse.bb b/meta-selftest/recipes-test/multiconfig/multiconfig-test-parse.bb
new file mode 100644
index 0000000000..6236697453
--- /dev/null
+++ b/meta-selftest/recipes-test/multiconfig/multiconfig-test-parse.bb
@@ -0,0 +1,11 @@
+SUMMARY = "Test Multiconfig Parsing"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
+
+INHIBIT_DEFAULT_DEPS = "1"
+
+do_showvar() {
+ bbplain "MCTESTVAR=${MCTESTVAR}"
+}
+addtask do_showvar
+
diff --git a/meta-selftest/recipes-test/postinst/postinst_1.0.bb b/meta-selftest/recipes-test/postinst/postinst_1.0.bb
new file mode 100644
index 0000000000..913bfabf89
--- /dev/null
+++ b/meta-selftest/recipes-test/postinst/postinst_1.0.bb
@@ -0,0 +1,72 @@
+SUMMARY = "Packages to exercise postinstall functions"
+LICENSE = "MIT"
+
+inherit allarch
+
+PACKAGES = "${PN}-rootfs ${PN}-delayed-a ${PN}-delayed-b ${PN}-rootfs-failing"
+
+ALLOW_EMPTY_${PN}-rootfs = "1"
+ALLOW_EMPTY_${PN}-delayed-a = "1"
+ALLOW_EMPTY_${PN}-delayed-b = "1"
+ALLOW_EMPTY_${PN}-rootfs-failing = "1"
+
+RDEPENDS_${PN}-delayed-a = "${PN}-rootfs"
+RDEPENDS_${PN}-delayed-b = "${PN}-delayed-a"
+
+TESTDIR = "${sysconfdir}/postinst-test"
+
+# At rootfs time touch $TESTDIR/rootfs. Errors if the file already exists, or
+# if the function runs on first boot.
+pkg_postinst_${PN}-rootfs () {
+ set -e
+
+ if [ -z "$D" ]; then
+ echo "${PN}-rootfs should have finished at rootfs time"
+ exit 1
+ fi
+
+ if [ -e $D${TESTDIR}/rootfs ]; then
+ echo "$D${TESTDIR}/rootfs exists, but should not"
+ exit 1
+ fi
+
+ mkdir -p $D${TESTDIR}
+ touch $D${TESTDIR}/rootfs
+}
+
+# Depends on rootfs, delays until first boot, verifies that the rootfs file was
+# written.
+pkg_postinst_ontarget_${PN}-delayed-a () {
+ set -e
+
+ if [ ! -e ${TESTDIR}/rootfs ]; then
+ echo "${PN}-delayed-a: ${TESTDIR}/rootfs not found"
+ exit 1
+ fi
+
+ touch ${TESTDIR}/delayed-a
+}
+
+# Depends on delayed-a, delays until first boot, verifies that the delayed-a file was
+# written. This verifies the ordering between delayed postinsts.
+pkg_postinst_ontarget_${PN}-delayed-b () {
+ set -e
+
+ if [ ! -e ${TESTDIR}/delayed-a ]; then
+ echo "${PN}-delayed-b: ${TESTDIR}/delayed-a not found"
+ exit 1
+ fi
+
+ touch ${TESTDIR}/delayed-b
+}
+
+# This scriptlet intentionally includes a bogus command in the middle to test
+# that we catch and report such errors properly.
+pkg_postinst_${PN}-rootfs-failing () {
+ mkdir -p $D${TESTDIR}
+ touch $D${TESTDIR}/rootfs-before-failure
+ run_a_really_broken_command
+ # Scriptlet execution should stop here; the following commands are NOT supposed to run.
+ # (oe-selftest checks for it).
+ touch $D${TESTDIR}/rootfs-after-failure
+}
diff --git a/meta-selftest/recipes-test/recipetool/selftest-recipetool-appendfile.bb b/meta-selftest/recipes-test/recipetool/selftest-recipetool-appendfile.bb
index 7d0a040beb..7375c47933 100644
--- a/meta-selftest/recipes-test/recipetool/selftest-recipetool-appendfile.bb
+++ b/meta-selftest/recipes-test/recipetool/selftest-recipetool-appendfile.bb
@@ -15,6 +15,8 @@ SRC_URI = "file://installscript.sh \
file://selftest-replaceme-inst-todir-globfile \
file://selftest-replaceme-inst-func"
+EXCLUDE_FROM_WORLD = "1"
+
install_extrafunc() {
install -m 0644 ${WORKDIR}/selftest-replaceme-inst-func ${D}${datadir}/selftest-replaceme-inst-func
}
diff --git a/meta-selftest/recipes-test/recipeutils/recipeutils-test.inc b/meta-selftest/recipes-test/recipeutils/recipeutils-test.inc
new file mode 100644
index 0000000000..8490b902d7
--- /dev/null
+++ b/meta-selftest/recipes-test/recipeutils/recipeutils-test.inc
@@ -0,0 +1,5 @@
+SRC_URI = "http://xorg.freedesktop.org/releases/individual/lib/libxshmfence-${PV}.tar.bz2"
+
+SRC_URI[md5sum] = "66662e76899112c0f99e22f2fc775a7e"
+SRC_URI[sha256sum] = "d21b2d1fd78c1efbe1f2c16dae1cb23f8fd231dcf891465b8debe636a9054b0c"
+
diff --git a/meta-selftest/recipes-test/recipeutils/recipeutils-test/anotherfile b/meta-selftest/recipes-test/recipeutils/recipeutils-test/anotherfile
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/meta-selftest/recipes-test/recipeutils/recipeutils-test/anotherfile
diff --git a/meta-selftest/recipes-test/recipeutils/recipeutils-test/somefile b/meta-selftest/recipes-test/recipeutils/recipeutils-test/somefile
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/meta-selftest/recipes-test/recipeutils/recipeutils-test/somefile
diff --git a/meta-selftest/recipes-test/recipeutils/recipeutils-test_1.2.bb b/meta-selftest/recipes-test/recipeutils/recipeutils-test_1.2.bb
new file mode 100644
index 0000000000..0cd0494da8
--- /dev/null
+++ b/meta-selftest/recipes-test/recipeutils/recipeutils-test_1.2.bb
@@ -0,0 +1,13 @@
+SUMMARY = "Test recipe for recipeutils.patch_recipe()"
+
+require recipeutils-test.inc
+
+LICENSE = "Proprietary"
+LIC_FILES_CHKSUM = "file://${WORKDIR}/somefile;md5=d41d8cd98f00b204e9800998ecf8427e"
+DEPENDS += "zlib"
+
+BBCLASSEXTEND = "native nativesdk"
+
+SRC_URI += "file://somefile"
+
+SRC_URI_append = " file://anotherfile"
diff --git a/meta-selftest/recipes-test/selftest-ed/selftest-ed_0.5.bb b/meta-selftest/recipes-test/selftest-ed/selftest-ed_0.5.bb
new file mode 100644
index 0000000000..8e0d1cdd8e
--- /dev/null
+++ b/meta-selftest/recipes-test/selftest-ed/selftest-ed_0.5.bb
@@ -0,0 +1,22 @@
+SUMMARY = "Line-oriented text editor -- selftest GPLv2 version"
+HOMEPAGE = "http://www.gnu.org/software/ed/"
+SECTION = "base"
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=6ddd5335ef96fb858a138230af773710 \
+ file://main.c;beginline=1;endline=17;md5=36d4b85e5ae9028e918d1cc775c2475e"
+
+PR = "r2"
+SRC_URI = "${SAVANNAH_GNU_MIRROR}/ed/ed-${PV}.tar.bz2"
+
+SRC_URI[md5sum] = "4ee21e9dcc9b5b6012c23038734e1632"
+SRC_URI[sha256sum] = "edef2bbde0fbf0d88232782a0eded323f483a0519d6fde9a3b1809056fd35f3e"
+
+inherit autotools texinfo
+
+S = "${WORKDIR}/ed-${PV}"
+
+EXTRA_OECONF = "'CC=${CC}' 'CXX=${CXX}' 'CFLAGS=${CFLAGS}' 'CXXFLAGS=${CXXFLAGS}' 'CPPFLAGS=${CPPFLAGS}' 'LDFLAGS=${LDFLAGS}'"
+
+CONFIGUREOPTS_remove = "--disable-dependency-tracking"
+CONFIGUREOPTS_remove = "--disable-silent-rules"
+EXTRA_OECONF_remove = "--disable-static"
diff --git a/meta-selftest/recipes-test/selftest-ed/selftest-ed_1.14.1.bb b/meta-selftest/recipes-test/selftest-ed/selftest-ed_1.14.1.bb
new file mode 100644
index 0000000000..8a2b565ce5
--- /dev/null
+++ b/meta-selftest/recipes-test/selftest-ed/selftest-ed_1.14.1.bb
@@ -0,0 +1,36 @@
+SUMMARY = "Line-oriented text editor -- selftest variant"
+HOMEPAGE = "http://www.gnu.org/software/ed/"
+
+LICENSE = "GPLv3+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=0c7051aef9219dc7237f206c5c4179a7 \
+ file://ed.h;endline=20;md5=4e36b7a40e137f42aee718165590d125 \
+ file://main.c;endline=17;md5=c5b8f78f115df187af76868a2aead16a"
+
+SECTION = "base"
+
+# LSB states that ed should be in /bin/
+bindir = "${base_bindir}"
+
+SRC_URI = "${GNU_MIRROR}/ed/ed-${PV}.tar.lz"
+RECIPE_NO_UPDATE_REASON = "This recipe is used in selftest and shouldn't be updated otherwise"
+
+SRC_URI[md5sum] = "7f4a54fa7f366479f03654b8af645fd0"
+SRC_URI[sha256sum] = "ffb97eb8f2a2b5a71a9b97e3872adce953aa1b8958e04c5b7bf11d556f32552a"
+
+S = "${WORKDIR}/ed-${PV}"
+
+EXTRA_OEMAKE = "-e MAKEFLAGS="
+
+inherit texinfo
+
+do_configure() {
+ ${S}/configure
+}
+
+do_install() {
+ oe_runmake 'DESTDIR=${D}' install
+ # Info dir listing isn't interesting at this point so remove it if it exists.
+ if [ -e "${D}${infodir}/dir" ]; then
+ rm -f ${D}${infodir}/dir
+ fi
+}
diff --git a/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink.bb b/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink.bb
new file mode 100644
index 0000000000..842a9772cb
--- /dev/null
+++ b/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink.bb
@@ -0,0 +1,30 @@
+LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302"
+
+LICENSE = "MIT"
+
+SRC_URI = "file://hello.c \
+ file://gdb.sh \
+"
+
+S = "${WORKDIR}"
+
+do_compile () {
+ ${CC} hello.c -o hello1 ${CFLAGS} ${LDFLAGS}
+}
+
+do_install () {
+ install -d ${D}${bindir}
+ install -m 755 ${WORKDIR}/gdb.sh ${D}${bindir}/
+ install -m 755 hello1 ${D}${bindir}/hello1
+ ln ${D}${bindir}/hello1 ${D}${bindir}/hello2
+
+ install -d ${D}${libexecdir}
+ ln ${D}${bindir}/hello1 ${D}${libexecdir}/hello3
+ ln ${D}${bindir}/hello1 ${D}${libexecdir}/hello4
+
+ dd if=/dev/zero of=${D}${bindir}/sparsetest bs=1 count=0 seek=1M
+}
+
+RDEPENDS_${PN}-gdb += "gdb"
+PACKAGES =+ "${PN}-gdb"
+FILES_${PN}-gdb = "${bindir}/gdb.sh"
diff --git a/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink/gdb.sh b/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink/gdb.sh
new file mode 100755
index 0000000000..f6417d5458
--- /dev/null
+++ b/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink/gdb.sh
@@ -0,0 +1,8 @@
+#!/bin/sh
+gdb -q $1 <<'EOF'
+b main
+r
+c
+q
+EOF
+echo ""
diff --git a/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink/hello.c b/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink/hello.c
new file mode 100644
index 0000000000..5c45dc60bd
--- /dev/null
+++ b/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink/hello.c
@@ -0,0 +1,5 @@
+#include <stdio.h>
+
+int main() {
+ printf("Hello World!\n");
+} \ No newline at end of file
diff --git a/meta-selftest/wic/test_biosplusefi_plugin.wks b/meta-selftest/wic/test_biosplusefi_plugin.wks
new file mode 100644
index 0000000000..5a56c84518
--- /dev/null
+++ b/meta-selftest/wic/test_biosplusefi_plugin.wks
@@ -0,0 +1,6 @@
+# short-description: This file is used in oe-selftest wic module to test biosplusefi plugin
+
+part /boot --source bootimg-biosplusefi --sourceparams="loader=grub-efi" --active --align 1024 --use-uuid
+part / --source rootfs --fstype=ext4 --align 1024 --use-uuid
+
+bootloader --timeout=0 --append="console=ttyS0,115200n8"
diff --git a/meta-selftest/wic/test_rawcopy_plugin.wks.in b/meta-selftest/wic/test_rawcopy_plugin.wks.in
new file mode 100644
index 0000000000..83be4be914
--- /dev/null
+++ b/meta-selftest/wic/test_rawcopy_plugin.wks.in
@@ -0,0 +1,6 @@
+# short-description: This file is used in oe-selftest wic module to test rawcopy plugin
+
+part /boot --active --source bootimg-pcbios
+part / --source rawcopy --sourceparams="file=core-image-minimal-${MACHINE}.ext4" --use-uuid
+
+bootloader --timeout=0 --append="console=ttyS0,115200n8"
diff --git a/meta-selftest/wic/wictestdisk.wks b/meta-selftest/wic/wictestdisk.wks
new file mode 100644
index 0000000000..d4de24d830
--- /dev/null
+++ b/meta-selftest/wic/wictestdisk.wks
@@ -0,0 +1,7 @@
+# short-description: image for use in machine agnostic wic test cases
+
+# /boot is intentionally an empty partition
+part /boot --ondisk sda --label boot --active --align 1024 --size 16
+part / --source rootfs --ondisk sda --fstype=ext4 --label platform --align 1024 --use-uuid
+
+# bootloader is intentionally left out