- 04 9月, 2015 2 次提交
-
-
由 Lukáš Doktor 提交于
Add simple script to see the "core" and "utils" unittest code coverage. Signed-off-by: NLukáš Doktor <ldoktor@redhat.com>
-
由 Lucas Meneghel Rodrigues 提交于
selftests/functional/test_interrupt.py: Fix NoSuchProcess bug
-
- 03 9月, 2015 8 次提交
-
-
由 Lucas Meneghel Rodrigues 提交于
If between psutil.procs() and the instantiation of the Process object the given pid has terminated, we'll get a NoSuchProcess error from psutils. Let's expand the list comprehension to avoid getting caught by such a condition. Signed-off-by: NLucas Meneghel Rodrigues <lmr@redhat.com>
-
由 Lucas Meneghel Rodrigues 提交于
Use standard unittest (and setuptools) for execution of selftests
-
由 Cleber Rosa 提交于
All other tests (unit and functional) are based on unittest. Let's do the same to this one, so that the default unittest discover code finds it and runs it. Signed-off-by: NCleber Rosa <crosa@redhat.com>
-
由 Cleber Rosa 提交于
Even though I may be the one to blame about coming up with this "simple import magic", I believe it was a mistake and we should get rid of them. There are a couple of other ways to actually do development out of of a source tree, including running unittests that do not require this amount of boiler plate code. Examples include just setting the PYTHONPATH environment variable to actually run (setuptools based) `python setup.py develop`. The little bits of what looks like the import magic that was left, is not really import magic. It's just that functional tests need to locate the Avocado source tree base directory to run the test runner from it. Signed-off-by: NCleber Rosa <crosa@redhat.com>
-
由 Cleber Rosa 提交于
One standard setuptools command is "test". That command does some useful setup and then runs the test in a verbose mode. There are a couple of reasons for activating that, including that setuptools can help us support a Python 3 version of Avocado by running 2to3 and even custom fixers before running the tests, or even builds and installs. Signed-off-by: NCleber Rosa <crosa@redhat.com>
-
由 Cleber Rosa 提交于
The unittest module, and unittest2 backport on Python 2.6, is capable of finding unittests and running them. So, effectively, we do not need nose at all. This patch removes the dependency on nose, replacing the run script with a version based solely on the unittest module. One change of functionality is that run now looks and runs tests in the standard selftests directories (unit, functional, doc), and does not accept command line arguments. If one wants to run a subset of them, it's pretty easy to just use the unittest module for that: $ python -m unittest discover -s selftests/unit Signed-off-by: NCleber Rosa <crosa@redhat.com>
-
由 Cleber Rosa 提交于
When running this functional test with the standard unittest discovery/runner it produces output that conflicts with the runner output. It looks like this output is not necessary for the test itself, and not that helpful for debugging purposes, so, let's just silence it. Signed-off-by: NCleber Rosa <crosa@redhat.com>
-
由 Cleber Rosa 提交于
To be honest, our test code could still be kept in the same directories and have the same names. But I think we can improve two things here: 1) Flatten a little bit the directory structure of selftests. Two path components are being dropped here: "all" and "avocado". So that "selftests/all/functional/avocado" becomes simply "selftests/functional". 2) File names match what is, by default, recognized by unittest (the Standard Library module) based discovery of tests. That means that doc_build_test.py becomes test_doc_build.py. Not a big deal IMHO. Signed-off-by: NCleber Rosa <crosa@redhat.com>
-
- 15 8月, 2015 2 次提交
-
-
由 Lucas Meneghel Rodrigues 提交于
[V3] Fix Ctrl+C for realz
-
由 Lucas Meneghel Rodrigues 提交于
Add functional automated tests for the Ctrl+C feature. They use aexpect and psutil, so add their dependencies to the relevant requirement files. Signed-off-by: NLucas Meneghel Rodrigues <lmr@redhat.com>
-
- 14 8月, 2015 12 次提交
-
-
由 Lucas Meneghel Rodrigues 提交于
examples/linuxbuild.py: Revert self.srcdir override
-
由 Lucas Meneghel Rodrigues 提交于
avocado.core.output: Fix mistake introduced in aa110812
-
由 Lucas Meneghel Rodrigues 提交于
Add some functional tests that ensure that we don't get caught by mistakes made when modifying the human test reporting code again (or at least, not by the obvious ones). Signed-off-by: NLucas Meneghel Rodrigues <lmr@redhat.com>
-
由 Lucas Meneghel Rodrigues 提交于
Inner Runner implementation [v2]
-
由 Lucas Meneghel Rodrigues 提交于
The correct mapping for FAIL tests is term_support.fail_str, not term_support.error_str. This will make FAIL tests to report as FAIL again. Signed-off-by: NLucas Meneghel Rodrigues <lmr@redhat.com>
-
由 Lucas Meneghel Rodrigues 提交于
With ldoktor's fix 136a78b6 this is unnecessary and we risk it being confused for people looking at the examples. Signed-off-by: NLucas Meneghel Rodrigues <lmr@redhat.com>
-
由 Lukáš Doktor 提交于
[V2] Output tweaks
-
由 Lukáš Doktor 提交于
avocado.core.job: Print variants after the tree representation
-
由 Lucas Meneghel Rodrigues 提交于
Change docs to show an output that reflects the current state of avocado. Signed-off-by: NLucas Meneghel Rodrigues <lmr@redhat.com>
-
由 Lucas Meneghel Rodrigues 提交于
Display the variants after the tree representation in the job log. Signed-off-by: NLucas Meneghel Rodrigues <lmr@redhat.com>
-
由 Lukáš Doktor 提交于
[V2] avocado.core.job: Log avocado temporary dir
-
由 Lucas Meneghel Rodrigues 提交于
Display the temporary directory in the job log. Signed-off-by: NLucas Meneghel Rodrigues <lmr@redhat.com>
-
- 13 8月, 2015 15 次提交
-
-
由 Lucas Meneghel Rodrigues 提交于
We are too verbose when Ctrl+C is pressed, we can convey a sufficient amount of information more concisely. Also, instead of printing the first message on the 2nd Ctrl+C pressed, print it right away so the user knows that avocado understood his/her request. Signed-off-by: NLucas Meneghel Rodrigues <lmr@redhat.com>
-
由 Lucas Meneghel Rodrigues 提交于
After a not so successful attempt to fix Ctrl+C management (see c400b2f4), I finally figured out the actual problem with the way we were doing handling: We just needed a clean way to break out of the test loop. Since TestRunner.run_test will return False if avocado received a Ctrl+C, let's use it to establish a condition for breaking the TestRunner.run_suite loop. Signed-off-by: NLucas Meneghel Rodrigues <lmr@redhat.com>
-
由 Lucas Meneghel Rodrigues 提交于
On commit d2d6623a, ldoktor changes the throbber color. This commit reverts the behavior to the one before the Ctrl+C reversion, since that'll be better in terms of bisectability. Signed-off-by: NLucas Meneghel Rodrigues <lmr@redhat.com>
-
由 Lucas Meneghel Rodrigues 提交于
This reverts commit c400b2f4. As a matter of fact the reversion had to be fixed due to a conflict with new code that entered that particular part of the code. The behavior previous to the commit was kept the same, so that we can change things in the next commits. Signed-off-by: NLucas Meneghel Rodrigues <lmr@redhat.com>
-
由 Cleber Rosa 提交于
In some external test suites, what is defined as a "test" can not be run by itself and need a specific runner script/tool. This introduces the concept of an "inner runner", that is, a custom test runner or tool that can deal with custom tests that do follow the Avocado SIMPLE test definition. This implements the Trello card: https://trello.com/c/TpXecE2n/486-introduce-inner-runner-to-avocado-run More information can be found in the man page section about it. Changes from v1: * removed "level" from "inner level runner" mentions * replicated docs from man page to "main" docs Signed-off-by: NCleber Rosa <crosa@redhat.com>
-
由 Lukáš Doktor 提交于
[V2] Fix unhelpful message when calling process/GDB APIs
-
由 Lukáš Doktor 提交于
Makefile: Modify avocado-vt plugin links
-
由 Lucas Meneghel Rodrigues 提交于
The process and gdb related APIs trust on subprocess.Popen to start a process. When shell=False and the command being executed is missing, Subprocss.Popen will raise an OSError with errno 2, with no additional message about what file is actually missing. OSError: [Errno 2] No such file or directory As you might have guessed, my workaround is to capture OSErrors with errno 2, and re-raise them with a more helpful message. 'File /usr/bin/gdbserver not found' Signed-off-by: NLucas Meneghel Rodrigues <lmr@redhat.com>
-
由 Lucas Meneghel Rodrigues 提交于
This is a slight tweak on the appearance of the test list in the human readable output - a single space between the beginning of the line and the beginning of the output (test numbering). Before: avocado run examples/tests/gdbtest.py JOB ID : 569340b20c85ed09a6164e8ce21e7b547e75802a JOB LOG : /home/lmr/avocado/job-results/job-2015-08-12T18.12-569340b/job.log TESTS : 21 (1/21) examples/tests/gdbtest.py:GdbTest.test_connect_multiple_clients: PASS (2.43 s) (2/21) examples/tests/gdbtest.py:GdbTest.test_disconnect: PASS (2.45 s) ... (21/21) examples/tests/gdbtest.py:GdbTest.test_stream_messages: PASS (0.15 s) RESULTS : PASS 21 | ERROR 0 | FAIL 0 | SKIP 0 | WARN 0 | INTERRUPT 0 JOB HTML : /home/lmr/avocado/job-results/job-2015-08-12T18.12-569340b/html/results.html TIME : 19.34 s After: avocado run examples/tests/gdbtest.py JOB ID : 569340b20c85ed09a6164e8ce21e7b547e75802a JOB LOG : /home/lmr/avocado/job-results/job-2015-08-12T18.12-569340b/job.log TESTS : 21 (1/21) examples/tests/gdbtest.py:GdbTest.test_connect_multiple_clients: PASS (2.43 s) (2/21) examples/tests/gdbtest.py:GdbTest.test_disconnect: PASS (2.45 s) ... (21/21) examples/tests/gdbtest.py:GdbTest.test_stream_messages: PASS (0.15 s) RESULTS : PASS 21 | ERROR 0 | FAIL 0 | SKIP 0 | WARN 0 | INTERRUPT 0 JOB HTML : /home/lmr/avocado/job-results/job-2015-08-12T18.12-569340b/html/results.html TIME : 19.34 s Signed-off-by: NLucas Meneghel Rodrigues <lmr@redhat.com>
-
由 Lucas Meneghel Rodrigues 提交于
Instead of showing it at the beginning, when it's not ready yet. Before: JOB ID : 751ceef63264d7749211875de16a0a719b80ccd3 JOB LOG : /home/lmr/avocado/job-results/job-2015-08-12T18.17-751ceef/job.log JOB HTML : /home/lmr/avocado/job-results/job-2015-08-12T18.17-751ceef/html/results.html TESTS : 1 (1/1) passtest.py:PassTest.test: PASS (0.00 s) RESULTS : PASS 1 | ERROR 0 | FAIL 0 | SKIP 0 | WARN 0 | INTERRUPT 0 TIME : 0.00 s After: JOB ID : b92df2a8389bbc0c3569263968ca6509ec562825 JOB LOG : /home/lmr/avocado/job-results/job-2015-08-12T18.17-b92df2a/job.log TESTS : 1 (1/1) passtest.py:PassTest.test: PASS (0.00 s) RESULTS : PASS 1 | ERROR 0 | FAIL 0 | SKIP 0 | WARN 0 | INTERRUPT 0 JOB HTML : /home/lmr/avocado/job-results/job-2015-08-12T18.17-b92df2a/html/results.html TIME : 0.00 s Signed-off-by: NLucas Meneghel Rodrigues <lmr@redhat.com>
-
由 Lucas Meneghel Rodrigues 提交于
With avocado-vt plugins renamed, 'make link' must change. ATTENTION: Please do a 'make clean' before applying this patch (or clean your source tree before 'make link'). Signed-off-by: NLucas Meneghel Rodrigues <lmr@redhat.com>
-
由 Lucas Meneghel Rodrigues 提交于
avocado.core.output: Use stdout to log test statuses
-
由 Lucas Meneghel Rodrigues 提交于
avocado.core.test: Use GDB-friendly srcdir
-
由 Lukáš Doktor 提交于
Throbber (test progress) supports two colors. Currently it turns green only when new status arrives, which is currently only used when we interrupt the test (GDB) or when the test finishes. Then the throbber turns green for one iteration and back to yellow in next iteration. This patch changes the behavior so the throbber is green when the test process is alive and yellow when it's interrupted. Signed-off-by: NLukáš Doktor <ldoktor@redhat.com>
-
由 Lukáš Doktor 提交于
The human output prints the test name, progress and pass/skip test statuses into stdout and fail/error/interrupt ones as stderr. This results in unreadable output. This patch logs all of them in stdout. Signed-off-by: NLukáš Doktor <ldoktor@redhat.com>
-
- 12 8月, 2015 1 次提交
-
-
由 Lukáš Doktor 提交于
Avocado allows the usage of GDB, but our default self.srcdir is incompatible with it causing many tests to fail. This patch simply replaces the ':' in basename to '_'. It's already created in a temporary directory, so there shouldn't be any name clashes. Signed-off-by: NLukáš Doktor <ldoktor@redhat.com>
-