X-Git-Url: http://git.efficios.com/?p=babeltrace.git;a=blobdiff_plain;f=tests%2Futils%2Fpython%2Fcli_params_to_string.py;h=4ff24987a4e672953e885430fe0e0c2c53bdfe4d;hp=90d61ffdc5e75dde47a63de4fb711324df40ae02;hb=5b616db96266d25cb0749e472cfc78c4944675e2;hpb=ab003dc0397a13f72c8268c310c0559a06a87fb1 diff --git a/tests/utils/python/cli_params_to_string.py b/tests/utils/python/cli_params_to_string.py index 90d61ffd..4ff24987 100644 --- a/tests/utils/python/cli_params_to_string.py +++ b/tests/utils/python/cli_params_to_string.py @@ -19,12 +19,13 @@ def to_string(p): ) elif type(p) is bt2._UnsignedIntegerValueConst: s = str(p) + "u" + elif type(p) is bt2._RealValueConst: + s = "{:.7f}".format(float(p)) elif ( type(p) in ( bt2._StringValueConst, bt2._SignedIntegerValueConst, - bt2._RealValueConst, bt2._BoolValueConst, ) or p is None