summaryrefslogtreecommitdiffstats
path: root/tests/Makefile
Commit message (Collapse)AuthorAgeFilesLines
* tests: Fix gcov typo for tmp105-testAndreas Färber2013-01-261-1/+1
| | | | | | | | Commit 6e9989034b176a8e4cfdccd85892abfa73977ba7 introduced a new qtest test case but misspelled gcov, leading to no coverage analysis. Fix it. Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* tests: adjust gcov variables for directory movementPaolo Bonzini2013-01-261-7/+7
| | | | | | | | I had missed the introduction of the gcov-files-* variables. Cc: Blue Swirl <blauwirbel@gmail.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* tests: Add tmp105 qtest test caseAndreas Färber2013-01-161-0/+3
| | | | | | | | | | Exercise all four commands of the TMP105, testing for an issue in the I2C TX path. The test case uses the N800's OMAP I2C and is the first for ARM. Signed-off-by: Andreas Färber <andreas.faerber@web.de> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* libqtest: Prepare I2C libqosAndreas Färber2013-01-161-0/+1
| | | | | | | | This adds a simple I2C API and a driver implementation for omap_i2c. Signed-off-by: Andreas Färber <andreas.faerber@web.de> Reviewed-by: Anthony Liguori <aliguori@us.ibm.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* build: fold trace-obj-y into libqemuutil.aPaolo Bonzini2013-01-121-4/+4
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* build: move base QAPI files to libqemuutil.aPaolo Bonzini2013-01-121-2/+1
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* build: move QAPI definitions for QEMU out of qapi-obj-yPaolo Bonzini2013-01-121-1/+1
| | | | | | | | | | | | | | There is no reason why for example qemu-ga should include all the definitions for the QEMU monitor. However, there are a few that are needed (qapi_free_SocketAddress, qapi_free_InetSocketAddress, ErrorClass_lookup). These should be moved to a separate "core" .json schema that goes into libqemuutil.a. For now, make this clearer by moving the qapi-*.o definitions out of libqemuutil.a. Once the above refactoring is done, qga-obj-y should not include anymore qapi-types.o and qapi-visit.o. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* build: move qobject files to qobject/ and libqemuutil.aPaolo Bonzini2013-01-121-7/+7
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* build: move files away from tools-obj-y, common-obj-y, user-obj-yPaolo Bonzini2013-01-121-5/+5
| | | | | | | | | | Split them between libqemuutil.a and, for those used by qemu-img/io/nbd, block-obj-y. Static libraries ensure that binaries such as qemu-ga do not include unused modules. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* build: move util-obj-y to libqemuutil.aPaolo Bonzini2013-01-121-9/+8
| | | | | | Use a static library to eliminate repetition in the linking rules. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* build: rename oslib-obj-y to util-obj-yPaolo Bonzini2013-01-121-1/+1
| | | | | | This prepares the creation of libqemuutil.a in the next patch. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* stubs: fully replace qemu-tool.c and qemu-user.cPaolo Bonzini2013-01-121-9/+9
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* tests: add gcov supportBlue Swirl2013-01-061-0/+43
| | | | | | | | | Add support for compiling for GCOV test coverage, enabled with '--enable-gcov' during configure. Test coverage will be reported after each test. Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* tests: add thread pool unit testsPaolo Bonzini2012-11-261-0/+2
| | | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* tests: add AioContext unit testsPaolo Bonzini2012-11-261-0/+2
| | | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* tests: link in stubsPaolo Bonzini2012-11-191-2/+2
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* build: do not include main loop where it is not actually usedPaolo Bonzini2012-10-301-4/+4
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* janitor: move iovector functions out of cutils.cPaolo Bonzini2012-10-301-1/+1
| | | | | | | This removes the dependency of cutils.c on iov.c, and lets us remove iov.o from several builds. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* tests: do not include tools-obj-yPaolo Bonzini2012-10-231-5/+5
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* block: Enable qemu_open/close to work with fd setsCorey Bryant2012-08-151-1/+1
| | | | | | | | | | | When qemu_open is passed a filename of the "/dev/fdset/nnn" format (where nnn is the fdset ID), an fd with matching access mode flags will be searched for within the specified monitor fd set. If the fd is found, a dup of the fd will be returned from qemu_open. Signed-off-by: Corey Bryant <coreyb@linux.vnet.ibm.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
* tests: Makefile: include dependency filesEduardo Habkost2012-07-281-0/+2
| | | | | | | | | | | | | | | Otherwise 'make check' won't recompile files that need to be recompiled because of header changes. To reproduce the bug, run: $ make check # succeeds $ echo B0RKED > hw/mc146818rtc_regs.h $ make check # is supposed to try to rebuild tests/rtc-test.o and fail Signed-off-by: Eduardo Habkost <ehabkost@redhat.com> Acked-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* qtest: Add hard disk geometry testMarkus Armbruster2012-07-171-0/+2
| | | | | | | So far covers only IDE and tests only CMOS contents. Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
* Merge remote-tracking branch 'mjt/mjt-iov2' into stagingAnthony Liguori2012-07-091-0/+2
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * mjt/mjt-iov2: rewrite iov_send_recv() and move it to iov.c cleanup qemu_co_sendv(), qemu_co_recvv() and friends export iov_send_recv() and use it in iov_send() and iov_recv() rename qemu_sendv to iov_send, change proto and move declarations to iov.h change qemu_iovec_to_buf() to match other to,from_buf functions consolidate qemu_iovec_copy() and qemu_iovec_concat() and make them consistent allow qemu_iovec_from_buffer() to specify offset from which to start copying consolidate qemu_iovec_memset{,_skip}() into single function and use existing iov_memset() rewrite iov_* functions change iov_* function prototypes to be more appropriate virtio-serial-bus: use correct lengths in control_out() message Conflicts: tests/Makefile Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
| * rewrite iov_* functionsMichael Tokarev2012-06-071-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This changes implementations of all iov_* functions, completing the previous step. All iov_* functions now ensure that this offset argument is within the iovec (using assertion), but lets to specify `bytes' value larger than actual length of the iovec - in this case they stops at the actual end of iovec. It is also suggested to use convinient `-1' value as `bytes' to mean just this -- "up to the end". There's one very minor semantic change here: new requiriment is that `offset' points to inside of iovec. This is checked just at the end of functions (assert()), it does not actually need to be enforced, but using any of these functions with offset pointing past the end of iovec is wrong anyway. Note: the new code in iov.c uses arithmetic with void pointers. I thought this is not supported everywhere and is a GCC extension (indeed, the C standard does not define void arithmetic). However, the original code already use void arith in iov_from_buf() function: (memcpy(..., buf + buf_off,...) which apparently works well so far (it is this way in qemu 1.0). So I left it this way and used it in other places. While at it, add a unit-test file test-iov.c, to check various corner cases with iov_from_buf(), iov_to_buf() and iov_memset(). Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
* | qapi: Unit tests for visitor-based serializationMichael Roth2012-06-081-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently we test our visitors individually, and seperately for input vs. output. This is useful for validating internal representations against the native C types and vice-versa, and other visitor-specific testing, but it doesn't cover the potential use-case of using visitor pairs for serialization/deserialization very well, and makes it hard to easily extend the coverage for different C types / boundary conditions. To cover that we add a set of unit tests that takes a number of native C values, passes them into an output visitor, extracts the values with an input visitor, then compares the result to the original. Plugging in new visitors to the test harness only requires a user to implement the SerializeOps interface and add it to a list. Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com> Signed-off-by: Andreas Färber <afaerber@suse.de>
* | build: do not sprinkle around GENERATED_HEADERS dependenciesPaolo Bonzini2012-06-071-1/+0
|/ | | | | | | | Keeping GENERATED_HEADERS dependencies up-to-date everywhere is complex. We can simply make the Makefile depend on them, and they will be built before all other targets. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* tests: Add rtc-test (fix test regression)Stefan Weil2012-05-211-1/+1
| | | | | | | | | | | Commit 93e9eb6808c886f5f1c903b7ced1eed65de2ba39 added fdc-test, but accidentally removed rtc-test because check-qtest-i386-y was not enhanced but set twice. This patch adds rtc-test again (and sorts both tests alphabetically). Signed-off-by: Stefan Weil <sw@weilnetz.de> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* tests: Fix linker failure for fdc-testStefan Weil2012-05-191-1/+1
| | | | | | | | | | | | | | | | | | When QEMU was built with the simple trace backend, linking failed: LINK tests/fdc-test oslib-posix.o: In function `trace_qemu_memalign': qemu/bin/debug/x86/./trace.h:31: undefined reference to `trace3' oslib-posix.o: In function `trace_qemu_vmalloc': qemu/bin/debug/x86/./trace.h:35: undefined reference to `trace2' oslib-posix.o: In function `trace_qemu_vfree': qemu/bin/debug/x86/./trace.h:39: undefined reference to `trace1' collect2: error: ld returned 1 exit status make: *** [tests/fdc-test] Fehler 1 Signed-off-by: Stefan Weil <sw@weilnetz.de> Reviewed-by: Kevin Wolf <kwolf@redhat.com> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* tests/Makefile: Add missing $(EXESUF)Kevin Wolf2012-05-101-2/+2
| | | | Signed-off-by: Kevin Wolf <kwolf@redhat.com>
* qtest: Add floppy testKevin Wolf2012-05-101-0/+2
| | | | | | | Let's start with testing media change. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
* qtest: add m48t59 tests for SparcBlue Swirl2012-04-211-0/+3
| | | | | | | Add simple m48t59 qtests, enable test only for Sparc32 and Sparc64. On PPC, the device is behind PCI bus. Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* tests: remove .SECONDARY special targetPaolo Bonzini2012-04-141-2/+0
| | | | | | | | | | | | The special target should not be needed anymore, and caused (perhaps due to a Make bug) a failure with "make -j2". In any case, the main makefile is a better place for such special targets rather than an included makefile. Reported-by: Luiz Capitulino <lcapitulino@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Tested-by: Luiz Capitulino <lcapitulino@redhat.com> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* qtest: fix out of tree buildBlue Swirl2012-03-301-0/+2
| | | | | | | Trace objects are also needed if tracing is enabled. Reviewed-by: Anthony Liguori <aliguori@us.ibm.com> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* qtest: add rtc-test test-caseAnthony Liguori2012-03-301-0/+5
| | | | | | Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* qtest: add C version of test infrastructureAnthony Liguori2012-03-301-3/+24
| | | | | | | | | This also includes a qtest wrapper script to make it easier to launch qtest tests directly. Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* test makefile overhaulPaolo Bonzini2012-03-301-44/+96
| | | | | | | | | | | | This introduces new test reporting infrastructure based on gtester and gtester-report. Also, all existing tests are moved to tests/, and tests/Makefile is reorganized to factor out the commonalities in the rules. Signed-off-by: Anthony Liguori <aliguori@linux.vnet.ibm.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* qapi: add strict mode to input visitorPaolo Bonzini2012-03-271-1/+4
| | | | | | | | | | | | While QMP in general is designed so that it is possible to ignore unknown arguments, in the case of the QMP server it is better to reject them to detect bad clients. In fact, we're already doing this at the top level in the argument checker. To extend this to complex structures, add a mode to the input visitor where it checks for unvisited keys and raises an error if it finds one. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
* test: add test-qmp-commands to make checkMichael Roth2012-03-261-0/+1
| | | | | | | | All the deps are here but the test was never added to the list of tests for make check Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com> Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
* test: remove qemu-ga referenceMichael Roth2012-03-261-1/+1
| | | | | | | This was added by mistake a while back. Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com> Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
* Add 'make check-block'Kevin Wolf2012-03-121-1/+6
| | | | | | Runs the full qemu-iotests suite for various image formats. Signed-off-by: Kevin Wolf <kwolf@redhat.com>
* make check: Add qemu-iotests subsetKevin Wolf2012-03-121-0/+5
| | | | | | Run the 'quick' group from qemu-iotests during 'make check'. Signed-off-by: Kevin Wolf <kwolf@redhat.com>
* qapi: add tests for string-based visitorsPaolo Bonzini2012-02-211-2/+10
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* tests: Silence gtester in MakefileStefan Weil2012-01-191-1/+1
| | | | | | | | This prettifies make output a little by avoiding a very long line. As gtester prints the checks when they are run, no information is lost. Signed-off-by: Stefan Weil <sw@weilnetz.de> Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
* test: eliminate libcheck tests and have make check use gtesterAnthony Liguori2012-01-121-5/+6
| | | | Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* build: split unit test builds to a separate makefile fragmentAnthony Liguori2012-01-121-0/+38
| | | | Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* tests: mv tests/* -> tests/tcgAnthony Liguori2012-01-121-145/+0
| | | | | Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* tests/Makefile: Remove qruncom targetChen Wei-Ren2011-12-091-6/+0
| | | | | | | | Remove qruncom target from the Makefile file. Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Chen Wei-Ren <chenwj@iis.sinica.edu.tw> Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
* lm32: opcode testsuiteMichael Walle2011-03-071-0/+4
| | | | | | | | This patch creates tests/lm32 directory and adds tests for every LatticeMico32 opcode. Signed-off-by: Michael Walle <michael@walle.cc> Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
* do not pass bogus $(SRC_PATH) include paths to cc during configurePaolo Bonzini2011-01-141-1/+2
| | | | | | | | | | Non-existent -I paths are dropped silently by the compiler, but still it is not polite to pass bogus options. Configure-time tests do not need any include files from the source path, so only include -I flags at make time (when they're properly expanded). Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* rewrite i386 tests MakefilePaolo Bonzini2010-10-231-42/+78
| | | | | | | | | | | | | 1) compute path to i386 compiler from configure. If it is found, run the i386 tests. I use macros so that this approach could be applied for other arches as well. 2) provide an easily extensible way to add tests Most tests fail, but at least "make test" does something meaningful. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
OpenPOWER on IntegriCloud