Go to file
Ricardo Martincoski 13e3c14ed2 support/testing: create default test case for python packages
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>
2018-11-13 20:55:45 +01:00
arch arch: drop BR2_GCC_TARGET_CPU_REVISION option 2018-10-01 14:52:32 +02:00
board configs/amarula_a64_relic: add WiFi support 2018-11-01 14:21:32 +01:00
boot uboot: bump to version 2018.09 2018-11-03 15:54:19 +01:00
configs configs/amarula_a64_relic: add WiFi support 2018-11-01 14:21:32 +01:00
docs Update for 2018.11-rc1 2018-11-09 22:56:48 +01:00
fs fs/f2fs: simplify overprovision option handling 2018-11-08 21:17:49 +01:00
linux linux: enable MICROCODE_INTEL if intel-microcode is selected 2018-11-12 22:27:32 +01:00
package python-aiodns: new package 2018-11-13 10:34:09 +01:00
support support/testing: create default test case for python packages 2018-11-13 20:55:45 +01:00
system system: update Config.in comment about systemd dependencies 2018-09-15 00:05:48 +02:00
toolchain toolchain/toolchain-buildroot: enable glibc for all little-endian ARCs with atomic ops 2018-11-09 22:02:16 +01:00
utils utils/scanpypi: use archive file name to specify the extraction folder 2018-11-02 21:35:08 +01:00
.defconfig
.flake8
.gitignore
.gitlab-ci.yml .gitlab-ci.yml: update after addition of TestF2FS test case 2018-11-08 22:41:53 +01:00
.gitlab-ci.yml.in .gitlab-ci.yml: do runtime tests only on explicit trigger 2018-10-21 23:34:18 +02:00
CHANGES Update for 2018.11-rc1 2018-11-09 22:56:48 +01:00
Config.in Config.in: security hardening: disable FORTIFY_SOURCE for gcc < 6 2018-11-06 08:54:25 +01:00
Config.in.legacy boot/xloader: remove package 2018-10-26 16:59:05 +02:00
COPYING
DEVELOPERS python-aiodns: new package 2018-11-13 10:34:09 +01:00
Makefile Update for 2018.11-rc1 2018-11-09 22:56:48 +01:00
Makefile.legacy
README

Buildroot is a simple, efficient and easy-to-use tool to generate embedded
Linux systems through cross-compilation.

The documentation can be found in docs/manual. You can generate a text
document with 'make manual-text' and read output/docs/manual/manual.text.
Online documentation can be found at http://buildroot.org/docs.html

To build and use the buildroot stuff, do the following:

1) run 'make menuconfig'
2) select the target architecture and the packages you wish to compile
3) run 'make'
4) wait while it compiles
5) find the kernel, bootloader, root filesystem, etc. in output/images

You do not need to be root to build or run buildroot.  Have fun!

Buildroot comes with a basic configuration for a number of boards. Run
'make list-defconfigs' to view the list of provided configurations.

Please feed suggestions, bug reports, insults, and bribes back to the
buildroot mailing list: buildroot@buildroot.org
You can also find us on #buildroot on Freenode IRC.

If you would like to contribute patches, please read
https://buildroot.org/manual.html#submitting-patches