summaryrefslogtreecommitdiffstats
path: root/support
Commit message (Collapse)AuthorAgeFilesLines
* support/download/dl-wrapper: fix urlencode option never being sent to backendDamien Thébault2018-12-091-1/+1
| | | | | | | | | | | | | | Since commit 38de434123 ("download: fix file:// BR2_PRIMARY_SITE (download cache)"), the urlencode option is no longer passed to the download backend, because we use ${backend} instead of ${backend_urlencode}. We must get the urlencode information from backend_urlencode. Signed-off-by: Damien Thébault <damien.thebault@vitec.com> Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr> [Thomas: rework commit log] Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/testing: drop docstring in TestPythonPackageBase::test_run()Thomas Petazzoni2018-12-081-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | Having a docstring in the test_run() method clutters the "run-tests -l" output: test_run (tests.package.test_python_crossbar.TestPythonPy3Crossbar) Test a python package. ... ok [...] test_run (tests.package.test_python_pexpect.TestPythonPy2Pexpect) Test a python package. ... ok test_run (tests.package.test_python_pexpect.TestPythonPy3Pexpect) Test a python package. ... ok test_run (tests.package.test_python_twisted.TestPythonPy2Twisted) Test a python package. ... ok test_run (tests.package.test_python_twisted.TestPythonPy3Twisted) Test a python package. ... ok test_run (tests.package.test_python_pynacl.TestPythonPy2Pynacl) Test a python package. ... ok test_run (tests.package.test_python_pynacl.TestPythonPy3Pynacl) Test a python package. ... ok So let's simply drop this docstring that is not particularly useful. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* support/testing: add prosody testFrancois Perrad2018-12-061-0/+48
| | | | | Signed-off-by: Francois Perrad <francois.perrad@gadz.org> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/testing: add lua testFrancois Perrad2018-12-061-0/+59
| | | | | | | Signed-off-by: Francois Perrad <francois.perrad@gadz.org> Reviewed-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Tested-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/testing: add perl-io-socket-ssl testFrancois Perrad2018-12-061-0/+21
| | | | | Signed-off-by: Francois Perrad <francois.perrad@gadz.org> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/testing: add perl-io-socket-multicast testFrancois Perrad2018-12-061-0/+21
| | | | | Signed-off-by: Francois Perrad <francois.perrad@gadz.org> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/testing: add perl-encode-decode testFrancois Perrad2018-12-061-0/+20
| | | | | Signed-off-by: Francois Perrad <francois.perrad@gadz.org> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/testing: add perl-dbd-mysql testFrancois Perrad2018-12-061-0/+21
| | | | | Signed-off-by: Francois Perrad <francois.perrad@gadz.org> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/testing/tests/packages/test_perl_*: regenerationFrancois Perrad2018-12-066-9/+9
| | | | | Signed-off-by: Francois Perrad <francois.perrad@gadz.org> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/scripts/graph-depends: introduce MANDATORY_DEPS arrayThomas Petazzoni2018-12-061-1/+6
| | | | | | | | | This array will be re-used in another function in a follow-up commit, so it makes sense to factor it out. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/scripts/graph-depends: use proper rootpkg in remove_extra_deps()Thomas Petazzoni2018-12-061-4/+4
| | | | | | | | | | | | | | | | | | | | | The remove_extra_deps() function removes dependencies that we are not interested in seeing in the dependency graph. It does this for all packages, except the 'all' package, which on full dependency graphs is the root of the tree. However, this doesn't take into account package-specific dependency graphs (i.e make <pkg>-graph-depends) where the root is not 'all', but '<pkg>'. Due to this, dependencies on "mandatory deps" were not visible at all, i.e the toolchain package (and its dependencies) and the skeleton package (and its dependencies) were not displayed in package-specific dependency graphs. To fix this, we use the existing rootpkg variable instead of hardcoding 'all'. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/graph-depends: drop legacy target-exceptionsYann E. MORIN2018-12-061-9/+0
| | | | | | | | | | | | | | | | | | | | | | | | Currently, we avoid drawing the dependencies that we call 'target exceptions', becasue they initially were returned by 'show-targets', when they in fact were not really packages and thus should not be on the graph. However, those two exceptions have no longer been reported in the output of show-targets since we merged very old initial top-level parallel build way back in 2014, with commit a24877586a56 (Makefile: add support for top-level parallel make), where they had been converted into purely internal rules. 4 years have passed, we can now drop those exceptions from the graph-depends script. This concludes the cleanup initiated three years ago with commit 0b32791f0076 (graph-depends: remove absent targets from TARGET_EXCEPTIONS). Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/testing: add perl-xml-libxml testFrancois Perrad2018-12-031-0/+22
| | | | | | | | Signed-off-by: Francois Perrad <francois.perrad@gadz.org> Reviewed-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> [https://gitlab.com/RicardoMartincoski/buildroot/-/jobs/124872335] Tested-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/testing: add perl-x10 testFrancois Perrad2018-12-031-0/+22
| | | | | | | | Signed-off-by: Francois Perrad <francois.perrad@gadz.org> Reviewed-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> [https://gitlab.com/RicardoMartincoski/buildroot/-/jobs/124872334] Tested-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/testing: add perl-mail-dkim testFrancois Perrad2018-12-031-0/+28
| | | | | | | | Signed-off-by: Francois Perrad <francois.perrad@gadz.org> Reviewed-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> [https://gitlab.com/RicardoMartincoski/buildroot/-/jobs/124872333] Tested-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/testing: add perl-libwww-perl testFrancois Perrad2018-12-031-0/+41
| | | | | | | | Signed-off-by: Francois Perrad <francois.perrad@gadz.org> Reviewed-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> [https://gitlab.com/RicardoMartincoski/buildroot/-/jobs/124872332] Tested-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/testing: add perl-gdgraph testFrancois Perrad2018-12-031-0/+22
| | | | | | | | Signed-off-by: Francois Perrad <francois.perrad@gadz.org> Reviewed-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> [https://gitlab.com/RicardoMartincoski/buildroot/-/jobs/124872330] Tested-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/testing: add perl-class-load testFrancois Perrad2018-12-031-0/+28
| | | | | | | | Signed-off-by: Francois Perrad <francois.perrad@gadz.org> Reviewed-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> [https://gitlab.com/RicardoMartincoski/buildroot/-/jobs/124872329] Tested-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* support/testing: add perl testFrancois Perrad2018-12-031-0/+66
| | | | | | | Signed-off-by: Francois Perrad <francois.perrad@gadz.org> Reviewed-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Tested-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
* Merge branch 'next'Peter Korsgaard2018-12-0260-177/+891
|\ | | | | | | Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
| * boot/grub2: add option to install toolsErico Nunes2018-11-261-0/+4
| | | | | | | | | | | | | | | | | | | | | | Add an option to install grub2 support tools to the target. In the context of Buildroot, some useful target tools provided are grub2-editenv, grub2-reboot, which provide means to manage the grub2, environment, boot order, and others. Signed-off-by: Erico Nunes <nunes.erico@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/scripts/check-host-rpath: split condition on two statementsThomas Petazzoni2018-11-261-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Inside the check_elf_has_rpath(), we check if the host binary has a correct RPATH, which should be either an absolute path to $(HOST_DIR)/lib, or a relative path using $ORIGIN. Those two conditions are checked in a single statements, but as we are going to add a third condition, let's split this up a bit: - If we have a RPATH to $(HOST_DIR)/lib -> we're good, return 0 - If we have a RPATH to $ORIGIN/../lib -> we're good, return 0 - Otherwise, we will exit the loop, and return 1 Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
| * support/dependencies: add a check for a suitable gzipYann E. MORIN2018-11-242-0/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Recently, some hash mismatch have been reported, both by users as well as autobuilder failures, about tarballs generated from git repositories. This turned out to be caused by users having the 'gzip' command somehow aliased to 'pigz' (which stand for: parallel implementation of gzip, which takes advantage of multi-processor system to parallelise the compression). Unfortunately, the output of pigz-compressed archives differ from that of gzip (even though they *are* valid gzip-compressed streams). Add a dependency check that ensures that gzip is not pigz. If that is the case, define a conditional dependency to host-gzip, that is used as a download dependency for packages that will generate compressed files, i.e. cvs, git, and svn. Fixes: http://autobuild.buildroot.org/results/330/3308271fc641cadb59dbf1b5ee529a84f79e6d5c/ Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Cc: Peter Korsgaard <peter@korsgaard.com> Cc: Arnout Vandecappelle <arnout@mind.be> Cc: Marcin Niestrój <m.niestroj@grinn-global.com> Cc: Erico Nunes <nunes.erico@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/dependencies: treat BSD-tar like the other casesYann E. MORIN2018-11-241-4/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, when we detect that tar is BSD-tar, we fake an unsupported version (major, minor) and rely on the version check to reject BSD-tar. There is no reason to use such shenanigans, when we can simply reject it from the onset. Simplify the logic: - use positive logic in the condition - directly exit in error Also, comment that case like the other cases are commented. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/kconfig/merge_config.sh: avoid false positive matches from comment linesNasser Afshin2018-11-243-3/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We are using empty CONFIG_PREFIX_. This results in false positive match for comment lines when merging config fragments. To avoid false positive reports, we use separate sed expressions and address comment lines explicitly. This is actually is in the Linux kernel mainline (v4.20-rc2): 6bbe4385d035c6fac56f840a59861a0310ce137b ("kconfig: merge_config: avoid false positive matches from comment lines") Signed-off-by: Nasser Afshin <Afshin.Nasser@gmail.com> Reviewed-by: Petr Vorel <petr.vorel@gmail.com> Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/kconfig/merge_config.sh: fix merging buildroot config filesNasser Afshin2018-11-243-1/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch allows us to define config prefix with CONFIG_ environment variable. By setting the proper config prefix, we will have proper 'redundant configuration warnings' when we use '-r -m' options. This is actually already in mainline for v4.20-rc1: 2cd3faf87d2d8f6123adf34741b9a7b98828a76f ("merge_config.sh: Allow to define config prefix") Signed-off-by: Nasser Afshin <afshin.nasser@gmail.com> Reviewed-by: Petr Vorel <petr.vorel@gmail.com> Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: add python-ubjson testsRicardo Martincoski2018-11-233-0/+47
| | | | | | | | | | | | | | | | Add a simple test case to check the basic usage, storing a dict into a file and then retrieving the dict from the file. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: add python-treq testsRicardo Martincoski2018-11-232-0/+45
| | | | | | | | | | | | | | | | | | Use a simple script to check the basic usage. The target has no https server, so a connection from in the target to localhost must not succeed. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: add python-subprocess32 testRicardo Martincoski2018-11-232-0/+17
| | | | | | | | | | | | | | | | Add a simple test case to check the basic usage by calling 'ls' and checking the output. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: add python-service-identity testsRicardo Martincoski2018-11-232-0/+25
| | | | | | | | | | | | | | Add a simple test case that imports the module. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: add python-pyyaml testsRicardo Martincoski2018-11-233-0/+47
| | | | | | | | | | | | | | | | Add a simple test case to check the basic usage, storing a dict into a file and then retrieving the dict from the file. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: add python-pynacl testsRicardo Martincoski2018-11-232-0/+30
| | | | | | | | | | | | | | | | | | Add a simple test case that minimally uses the module. Add haveged to the target to generate enough entropy so pynacl -> libsodium don't hang waiting for /dev/random. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: add python-pexpect testsRicardo Martincoski2018-11-232-0/+29
| | | | | | | | | | | | | | | | Add a simple test case to check the basic usage. Call 'login' and try wrong user/password, expecting the 'Login incorrect' message. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: add python-passlib testsRicardo Martincoski2018-11-232-0/+28
| | | | | | | | | | | | | | | | Add a simple test case that creates a hash for a password and verifies it against an incorrect and a correct password. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: add python-constantly testsRicardo Martincoski2018-11-232-0/+40
| | | | | | | | | | | | | | | | Add a simple test case to check the basic usage by creating a class with two constants. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: add python-click testsRicardo Martincoski2018-11-232-0/+56
| | | | | | | | | | | | | | | | | | Use a simple script to check the basic usage. Since this package provides command line arguments, override run_sample_scripts to call the script with arguments and check the expected output. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: add python-cbor testsRicardo Martincoski2018-11-233-0/+47
| | | | | | | | | | | | | | | | Add a simple test case to check the basic usage, storing a dict into a file and then retrieving the dict from the file. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: add python-bitstring testsRicardo Martincoski2018-11-232-0/+27
| | | | | | | | | | | | | | | | | | Add a simple test case to check the basic usage by checking the corresponding representation of a 12-bit decimal number in hex, binary and integer. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: add python-automat testsRicardo Martincoski2018-11-232-0/+50
| | | | | | | | | | | | | | | | Use a minimal script to check the basic usage by creating and using a small state machine. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: add python-attrs testsRicardo Martincoski2018-11-232-0/+36
| | | | | | | | | | | | | | | | Use a minimal script to check the basic usage creating a class with 2 attributes. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: add python-argh testsRicardo Martincoski2018-11-232-0/+55
| | | | | | | | | | | | | | | | | | Use a simple script to check the basic usage. Since this package provides command line arguments, override run_sample_scripts to call the script with arguments and check the expected output. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing/test_rust: use standard defconfig fragment styleRicardo Martincoski2018-11-201-39/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since commit "2927f412be support/testing: standardize defconfig fragments style" all other test cases use the same style for defconfig fragments: - start after a backslash; - be declared as a multi-line string literal; - be indented one level more than the variable that contains it. Do the same here for consistency. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Cc: Matt Weber <matthew.weber@rockwellcollins.com> Reviewed-by: Matt Weber <matthew.weber@rockwellcollins.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: add python-crossbar testsYegor Yefremov2018-11-132-0/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This test invokes "crossbar version" command, that checks all dependencies found in setup.py files and prints some system related information. Add haveged to the target to generate enough entropy so crossbar -> pynacl -> libsodium don't hang waiting for /dev/random. Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com> [Ricardo: move test script to a separate file, remove Python 2 variant, add haveged to target to add entropy and avoid hanging] Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: use TestPythonPackageBase for python-txtorconRicardo Martincoski2018-11-132-20/+12
| | | | | | | | | | | | | | | | | | | | | | | | Move the test script to be run on the target from inline in the test case to a separate file. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Cc: Arnout Vandecappelle <arnout@mind.be> Cc: Asaf Kahlon <asafka7@gmail.com> Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Cc: Yegor Yefremov <yegorslists@googlemail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: use TestPythonPackageBase for python-txaioRicardo Martincoski2018-11-133-21/+15
| | | | | | | | | | | | | | | | | | | | | | | | Move the test scripts to be run on the target from inline in the test case to a separate file. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Cc: Arnout Vandecappelle <arnout@mind.be> Cc: Asaf Kahlon <asafka7@gmail.com> Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Cc: Yegor Yefremov <yegorslists@googlemail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: use TestPythonPackageBase for python-twistedRicardo Martincoski2018-11-132-25/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Move the test script to be run on the target from inline in the test case to a separate file. Get the base defconfig fragment from the immediate parent class and not directly from TestPythonBase because it is the correct way of doing this. This way the base class TestPythonTwisted could even be placed in a separate file. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Cc: Arnout Vandecappelle <arnout@mind.be> Cc: Asaf Kahlon <asafka7@gmail.com> Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Cc: Yegor Yefremov <yegorslists@googlemail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: use TestPythonPackageBase for python-incrementalRicardo Martincoski2018-11-132-22/+14
| | | | | | | | | | | | | | | | | | | | | | | | Move the test script to be run on the target from inline in the test case to a separate file. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Cc: Arnout Vandecappelle <arnout@mind.be> Cc: Asaf Kahlon <asafka7@gmail.com> Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Cc: Yegor Yefremov <yegorslists@googlemail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: use TestPythonPackageBase for python-cryptographyRicardo Martincoski2018-11-132-22/+14
| | | | | | | | | | | | | | | | | | | | | | | | Move the test script to be run on the target from inline in the test case to a separate file. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Cc: Arnout Vandecappelle <arnout@mind.be> Cc: Asaf Kahlon <asafka7@gmail.com> Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Cc: Yegor Yefremov <yegorslists@googlemail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: use TestPythonPackageBase for python-autobahnRicardo Martincoski2018-11-132-20/+10
| | | | | | | | | | | | | | | | | | | | | | | | Move the test script to be run on the target from inline in the test case to a separate file. Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Cc: Arnout Vandecappelle <arnout@mind.be> Cc: Asaf Kahlon <asafka7@gmail.com> Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Cc: Yegor Yefremov <yegorslists@googlemail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
| * support/testing: create default test case for python packagesRicardo Martincoski2018-11-132-0/+63
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Test cases for python packages are very similar among each other: run a simple script in the target that minimally tests the package. So create a new helper class named TestPythonPackageBase that holds all the logic to run a script on the target. TestPythonPackageBase adds in build time one or more sample scripts to be run on the target. The test case for the python package must explicitly list them in the "sample_scripts" property. The test case then automatically logins to the target, checks the scripts are really in the rootfs (it calls "md5sum" instead of "ls" or "test" in an attempt to make the logfile more friendly, since someone analysing a failure can easily check the expected script was executed) and then calls the python interpreter passing the sample script as parameter. An optional property "timeout" exists for the case the sample script needs more time to run than the default timeout from the test infra (currently 5 seconds). A simple test case for a package that only supports Python 2 will look like this: |from tests.package.test_python import TestPythonPackageBase | | |class TestPythonPy2<Package>(TestPythonPackageBase): | __test__ = True | config = TestPythonPackageBase.config + \ | """ | BR2_PACKAGE_PYTHON=y | BR2_PACKAGE_PYTHON_<PACKAGE>=y | """ | sample_scripts = ["tests/package/sample_python_<package>.py"] | timeout = 15 Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Cc: Arnout Vandecappelle <arnout@mind.be> Cc: Asaf Kahlon <asafka7@gmail.com> Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Cc: Yegor Yefremov <yegorslists@googlemail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
OpenPOWER on IntegriCloud