mirror of
https://git.yoctoproject.org/poky
synced 2026-04-29 18:32:20 +02:00
Where there isn't a copyright statement, add one to make it explicit. Also add license identifiers as MIT if there isn't one. (From OE-Core rev: bb731d1f3d2a1d50ec0aed864dbca54cf795b040) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
25 lines
880 B
Python
25 lines
880 B
Python
#
|
|
# Copyright OpenEmbedded Contributors
|
|
#
|
|
# SPDX-License-Identifier: MIT
|
|
#
|
|
|
|
import shutil
|
|
import os.path
|
|
from oeqa.sdk.case import OESDKTestCase
|
|
|
|
class SanityTests(OESDKTestCase):
|
|
def test_tools(self):
|
|
"""
|
|
Test that wget and tar come from the buildtools, not the host. This
|
|
verifies that the buildtools have installed correctly. We can't check
|
|
for gcc as that is only installed by buildtools-extended.
|
|
"""
|
|
for command in ("tar", "wget"):
|
|
# Canonicalise the SDK root
|
|
sdk_base = os.path.realpath(self.tc.sdk_dir)
|
|
# Canonicalise the location of this command
|
|
tool_path = os.path.realpath(self._run("command -v %s" % command).strip())
|
|
# Assert that the tool was found inside the SDK root
|
|
self.assertEquals(os.path.commonprefix((sdk_base, tool_path)), sdk_base)
|