bt2: Adapt test_graph.py and make it pass
This patch updates test_graph.py and graph.py to work with the current
BT API.
An important change is that now, the port added and ports connected
listeners can report their failures up the stack. Therefore, if a
Python listener raises an exception, we now report it as an error. Some
tests are added for this.
The tests:
- test_connect_ports_canceled
- test_connect_ports_cannot_consume_accept
- test_connect_ports_cannot_consume_connected
were removed, since the library no longer returns an error in these
situations (they are just verified by precondition check). However, a
test was added to check that when the graph gets cancelled during
execution, a bt2.GraphCanceled gets raised.
Some changes in message.py, message_iterator.py and port.py are
necessary to support the test. They are not complete, but they are
representative of what will come after.
Any reference to ports being removed or disconnected were removed, since
it's not longer possible to remove or disconnect a port.
Change-Id: Ie8f11553f34208bb58242d9108efc361acba3c18
Signed-off-by: Simon Marchi <simon.marchi@efficios.com>
Signed-off-by: Francis Deslauriers <francis.deslauriers@efficios.com>
Reviewed-on: https://review.lttng.org/c/babeltrace/+/1317
Reviewed-by: Philippe Proulx <eeppeliteloop@gmail.com>
Tested-by: jenkins
This page took 0.026319 seconds and 4 git commands to generate.