bt2: Adapt test_packet.py and make it pass
authorSimon Marchi <simon.marchi@efficios.com>
Tue, 14 May 2019 19:38:58 +0000 (15:38 -0400)
committerPhilippe Proulx <eeppeliteloop@gmail.com>
Wed, 5 Jun 2019 17:47:34 +0000 (13:47 -0400)
commit838a5a5273dc2296b0e08d20e2e0f24183e68b5e
tree51a9fdc18ccf86d98a3f6794d3e90c8c26e47ce6
parentbe7bbff934d18e407853436dd9f7da23c8c20743
bt2: Adapt test_packet.py and make it pass

This patch updates test_packet.py and packet.py to work with the current
API.

In both files, everything about equality, copy, deep copy and header
fields is removed.  The setter for context_field is also removed.

One side-effect change (required for the test) is in the
Field.field_class property.  Previously, when creating a Field object
wrapping a bt_field pointer, we would create the corresponding
FieldClass object and store it in Field._field_class.  Instead, we can
compute it as needed in the Field.field_class property, I don't really
see any problem with that.

Change-Id: I509b3bd272fb323ed6df7de47d21c31b8aedc72f
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/+/1301
Tested-by: jenkins
Reviewed-by: Philippe Proulx <eeppeliteloop@gmail.com>
bindings/python/bt2/bt2/field.py
bindings/python/bt2/bt2/packet.py
tests/bindings/python/bt2/test_packet.py
This page took 0.025056 seconds and 4 git commands to generate.