summaryrefslogtreecommitdiffstats
path: root/lldb/packages/Python/lldbsuite/test/tools/lldb-server
Commit message (Collapse)AuthorAgeFilesLines
...
* Fix TestPlatformProcessConnect after rL265357Tamas Berghammer2016-04-051-1/+5
| | | | llvm-svn: 265392
* Don't vary debug info for lldb-server testsPavel Labath2016-03-311-0/+2
| | | | | | | | | | | | | | | | | | Summary: Debug info is used only by the client and lldb-server tests do not even have the client component running, as they communicate with the server directly. Therefore, running the tests for each debug info type is unnecessarry. This adds general ability to mark a test class as not dependent on debug info, and marks all lldb-server tests as such. Reviewers: tberghammer, tfiala Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D18598 llvm-svn: 265017
* Mark an LLGS test as flakyPavel Labath2016-03-161-0/+1
| | | | | cause: Async output arrival over pty llvm-svn: 263631
* [test] Persist packets between expect_gdbremote_sequence invocationsPavel Labath2016-03-163-30/+41
| | | | | | | | | | | | | | | | | | | | | | Summary: Some tests (Hc_then_Csignal_signals_correct_thread, at least) were sending a "continue" packet in one expect_gdbremote_sequence invocation, and "expecting" the stop-reply in another call. This posed a problem, because the were packets were not persisted between the two invocations, and if the stub was exceptionally fast to respond, the packet would be received in the first invocation (where it would be ignored) and then the second invocation would fail because it could not find the packet. Since doing matching in two invocations seems like a reasonable use of the packet pump, instead of fixing the test, I make sure the packet_pump supports this usage by making the list of captured packets persistent. Reviewers: tfiala Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D18140 llvm-svn: 263629
* [test] Correctly retry connections on android targetsPavel Labath2016-03-141-5/+31
| | | | | | | | | | | | | | | | | Summary: Normally, when the remote stub is not ready, we will get ECONNREFUSED during the connect() attempt. However, due to the way how ADB forwarding works, on android targets the connect() will always be successful, but the connection will be immediately dropped if ADB could not connect on the remote side. This commit tries to detect this situation, and report it as "connection refused" so that the upper test layers attempt the connection again. Reviewers: tfiala, tberghammer Subscribers: tberghammer, danalbert, srhines, lldb-commits Differential Revision: http://reviews.llvm.org/D18146 llvm-svn: 263439
* Add a log statementPavel Labath2016-03-041-0/+1
| | | | llvm-svn: 262715
* Resumbit "Fetch remote log files from LLGS tests"Pavel Labath2016-03-041-5/+29
| | | | | | | | The problem with the original patch (and my first attempt to fix) was that the value debug monitor flags could persist from one test to another. Resetting the value in the setUp() function fixes the problem. llvm-svn: 262713
* Revert "Fetch remote log files from LLGS tests"Pavel Labath2016-03-031-29/+5
| | | | | | | Even after the last fixup, there still seems to be one failure left. Revert until I figure out what is going on. llvm-svn: 262622
* Fix OSX breakage caused by r262597Pavel Labath2016-03-031-0/+1
| | | | llvm-svn: 262602
* Fetch remote log files from LLGS testsPavel Labath2016-03-031-5/+28
| | | | | | | | | | | | | | | | | Summary: this enables download of remote log files for llgs and debugserver tests (previously we were just passing the host file name which obviously did not work). Note this also changes the debugserver logging to work only when logging has been requested on the command line, whereas previously it would log unconditionally. I can change it back if anyone is relying on this, but I thought I'd make this consistent. Reviewers: tfiala Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D17798 llvm-svn: 262597
* Slightly improve logging in LLGS testsPavel Labath2016-03-011-1/+1
| | | | | | we're sometimes getting an exception here, and I want to see why... llvm-svn: 262333
* Make TestPlatformProcessConnect to support abstract/domain sockets.Oleksiy Vyalov2016-02-261-4/+20
| | | | llvm-svn: 261974
* Remove expectedFailureFreeBSD decoratorEd Maste2016-02-191-1/+1
| | | | | | | | All invocations are updated to use the generic expectedFailureAll. Differential Revision: http://reviews.llvm.org/D17455 llvm-svn: 261355
* Mark TestLldbGdbServer.test_software_breakpoint_set_and_remove_work_llgs as ↵Pavel Labath2016-02-191-0/+1
| | | | | | | | flaky on linux The problem is the asynchronous arrival of inferior stdio (pr25652). llvm-svn: 261313
* Mark TestLldbGdbServer.test_written_M_content_reads_back_correctly as flaky ↵Pavel Labath2016-02-161-0/+1
| | | | | | | | on linux I believe the root cause is the asynchronous arrival of inferior stdio (pr25652). llvm-svn: 260950
* Remove expectedFailureLinux decorator.Zachary Turner2016-02-102-3/+3
| | | | llvm-svn: 260422
* Bump up the packet timeout for gdbremote testsPavel Labath2016-02-051-1/+1
| | | | | | | Log confirmed that the we are sometimes timing out on the receive, even though the server is sending the correct packets. llvm-svn: 259878
* Move the rest of the tests over to using the new decorator module.Zachary Turner2016-02-0416-11/+37
| | | | llvm-svn: 259838
* Move some of the common decorators to decorators.py.Zachary Turner2016-02-041-1/+2
| | | | | | | | | | | | This doesn't attempt to move every decorator. The reason for this is that it requires touching every single test file to import decorators.py. I would like to do this in a followup patch, but in the interest of keeping the patches as bite-sized as possible, I've only attempted to move the underlying common decorators first. A few tests call these directly, so those tests are updated as part of this patch. llvm-svn: 259807
* Add verbose logging support to gdb-remote testsPavel Labath2016-02-041-7/+39
| | | | | | | | | | | | | | | | | | Summary: gdb-remote tests are not able to use the same logging mechanisms as the rest of our tests, and currently we get no host logs from them, even though the tests themselves have logging capability. This commit changes that. When user specifies that he would like to log the gdb-remote channel (--channel gdb-remote argument to dotest.py), we write detailed logs to the <TEST_ID>-host.log file, just like we would in the case of regular tests. If this argument is not specified, we only log the serious messages to stderr, which matches the existing behaviour. Reviewers: tfiala, tberghammer Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D16858 llvm-svn: 259774
* Always write the session file in UTF-8.Zachary Turner2016-02-011-1/+2
| | | | | | | | | | | | | | | | | | This patch attempts to solve the Python 2 / Python 3 incompatibilities by introducing a new `encoded_file` abstraction that we use instead of `io.open()`. The problem with the builtin implementation of `io.open` is that `read` and `write` accept and return `unicode` objects, which are not always convenient to work with in Python 2. We solve this by making `encoded_file.open()` return the same object returned by `io.open()` but with hooked `read()` and `write()` methods. These hooked methods will accept binary or text data, and conditionally convert what it gets to a `unicode` object using the correct encoding. When calling `read()` it also does any conversion necessary to convert the output back into the native `string` type of the running python version. Differential Revision: http://reviews.llvm.org/D16736 llvm-svn: 259379
* Mark arm/aarch64 specific xfails with expectedFailureLinux decoratorOmair Javaid2016-01-202-3/+6
| | | | | | | | | | | | | This patch marks some known failures and puts on expectedFailureLinux decorator to have testsuite xfail them. Affected tests are: test/functionalities/watchpoint/step_over_watchpoint.py test/functionalities/watchpoint/watchpoint_set_command/TestWatchLocationWithWatchSet.py test/tools/lldb-server/TestGdbRemoteSingleStep.py test/tools/lldb-server/TestGdbRemote_vCont.py llvm-svn: 258315
* Centralize the handling of attach permissions on linux in testsPavel Labath2016-01-111-14/+1
| | | | | | | | | | | | | | | Summary: On linux we need the process to give us special permissions before we can attach to it. Previously, the code for this was copied into every file that needed it. This moves the code to a central place to reduce code duplication. Reviewers: clayborg Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D15992 llvm-svn: 257319
* XFAIL some tests failing for Windows -> AndroidTamas Berghammer2015-12-171-0/+1
| | | | llvm-svn: 255885
* Fix a cleanup error in TestPlatformProcessConnect.pyTamas Berghammer2015-12-091-1/+1
| | | | llvm-svn: 255104
* Modify "platform connect" to connect to processes as wellTamas Berghammer2015-12-084-15/+83
| | | | | | | | | | | | | | | | | | | | | | | | The standard remote debugging workflow with gdb is to start the application on the remote host under gdbserver (e.g.: gdbserver :5039 a.out) and then connect to it with gdb. The same workflow is supported by debugserver/lldb-gdbserver with a very similar syntax but to access all features of lldb we need to be connected also to an lldb-platform instance running on the target. Before this change this had to be done manually with starting a separate lldb-platform on the target machine and then connecting to it with lldb before connecting to the process. This change modifies the behavior of "platform connect" with automatically connecting to the process instance if it was started by the remote platform. With this command replacing gdbserver in a gdb based worflow is usually as simple as replacing the command to execute gdbserver with executing lldb-platform. Differential revision: http://reviews.llvm.org/D14952 llvm-svn: 255016
* Get rid of global variables in dotest.pyZachary Turner2015-12-081-4/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | This moves all the global variables into a separate module called `configuration`. This has a number of advantages: 1. Configuration data is centrally maintained so it's easy to get a high level overview of what configuration data the test suite makes use of. 2. The method of sharing configuration data among different parts of the test suite becomes standardized. Previously we would put some things into the `lldb` module, some things into the `lldbtest_config` module, and some things would not get shared. Now everything is shared through one module and is available to the entire test suite. 3. It opens the door to moving some of the initialization code into the `configuration` module, simplifying the implementation of `dotest.py`. There are a few stragglers that didn't get converted over to using the `configuration` module in this patch, because it would have grown the size of the patch unnecessarily. This includes everything currently in the `lldbtest_config` module, as well as the `lldb.remote_platform` variable. We can address these in the future. llvm-svn: 254982
* [LLDB][MIPS] Fix gdbremote_testcase.pyMohit K. Bhakkad2015-12-041-3/+9
| | | | | | | | | | Patch by Nitesh Jain Reviewers: clayborg, ovyalov. Subscribers: jaydeep, bhushan, mohit.bhakkad, sagar. Differential Revision: http://reviews.llvm.org/D15103 llvm-svn: 254711
* Support unix-abstract-connect scheme as platform url in lldb testsuiteYing Chen2015-11-181-2/+6
| | | | | | | | | | Reviewers: ovyalov Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D14765 llvm-svn: 253488
* Marked test_qRegisterInfo_returns_{one_valid_result,all_valid_results} XFAIL ↵Todd Fiala2015-11-111-0/+2
| | | | | | | | | on Darwin. Tracked by: https://llvm.org/bugs/show_bug.cgi?id=25486 llvm-svn: 252707
* Python 3 - Port use of string.maketrans and don't use sets.Set.Zachary Turner2015-11-061-2/+1
| | | | | | | | | | `sets.Set` has been deprecated in favor of `set` since 2.6, and `string.maketrans` has to be special cased. In Python 3 there is `str.maketrans`, `bytes.maketrans`, and `bytearray.maketrans` and you have to choose the correct one. So we need to introduce a runtime version check at this site. llvm-svn: 252348
* Remove `use_lldb_suite` from the package, and don't import it anymore.Zachary Turner2015-11-0319-19/+19
| | | | | | | | | | | | | | | | This module was originally intended to be imported by top-level scripts to be able to find the LLDB packages and third party libraries. Packages themselves shouldn't need to import it, because by the time it gets into the package, the top-level script should have already done this. Indeed, it was just adding the same values to sys.path multiple times, so this patch is essentially no functional change. To make sure it doesn't get re-introduced, we also delete the `use_lldb_suite` module from `lldbsuite/test`, although the original copy still remains in `lldb/test` llvm-svn: 251963
* Tighten up sys.path, and use absolute imports everywhere.Zachary Turner2015-11-0318-19/+19
| | | | | | | | | | | | | | | | | | | | For convenience, we had added the folder that dotest.py was in to sys.path, so that we could easily write things like `import lldbutil` from anywhere and any test. This introduces a subtle problem when using Python's package system, because when unittest2 imports a particular test suite, the test suite is detached from the package. Thus, writing "import lldbutil" from dotest imports it as part of the package, and writing the same line from a test does a fresh import since the importing module was not part of the same package. The real way to fix this is to use absolute imports everywhere. Instead of writing "import lldbutil", we need to write "import lldbsuite.test.util". This patch fixes up that and all other similar cases, and additionally removes the script directory from sys.path to ensure that this can't happen again. llvm-svn: 251886
* Move lldb/test to lldb/packages/Python/lldbsuite/test.Zachary Turner2015-10-2824-0/+5807
This is the conclusion of an effort to get LLDB's Python code structured into a bona-fide Python package. This has a number of benefits, but most notably the ability to more easily share Python code between different but related pieces of LLDB's Python infrastructure (for example, `scripts` can now share code with `test`). llvm-svn: 251532
OpenPOWER on IntegriCloud