test_{field,value}.py: test complex number RHS for binary operations
authorPhilippe Proulx <eeppeliteloop@gmail.com>
Sat, 29 Jun 2019 16:16:38 +0000 (12:16 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Thu, 18 Jul 2019 15:53:33 +0000 (11:53 -0400)
commit229e22278b9f600d706c52dd6334c050c0c476c7
tree3709a1c52b0a5e80331d4a6b2966047d2bd02a0a
parenta19825c653f89bc67b68e29d4bdbcfe30f341247
test_{field,value}.py: test complex number RHS for binary operations

This patch adds injected tests for numeric field and value test cases in
which the RHS operand of the tested binary operations is a complex
number, both `-23+19j` and `0j`.

This is to ensure that a binary operator applied to a field object or a
value object and a Python complex number returns what's expected by the
langage, so you can do:

    print(my_field + 8+4.2j)

if you wish.

Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
Change-Id: I5cade062e285752d0a917a8b751824b0ebc97f16
Reviewed-on: https://review.lttng.org/c/babeltrace/+/1587
Tested-by: jenkins <jenkins@lttng.org>
Reviewed-by: Francis Deslauriers <francis.deslauriers@efficios.com>
tests/bindings/python/bt2/test_field.py
tests/bindings/python/bt2/test_value.py
This page took 0.025075 seconds and 4 git commands to generate.