NetworkManager/clients
Thomas Haller ad3ef326aa clients/tests: don't include the source line number with client tests output
The client tests compare the test output with a .expected file that is
commit to git and that contains the expected output.

The expected output contains data like

    size: 395
    location: clients/tests/test-client.py:842:test_001()/1
    cmd: $NMCLI
    lang: C
    returncode: 0
    stdout: 277 bytes
    >>>
    ...

Note that there is the line number (clients/tests/test-client.py:842) of
the source code where nmcli is called. This is to help correlate the output
with the test code.

However, Python 3.8 changes behavior and for function calls that span multiple
lines, frame.f_lineno will give now the starting line (previously, it gave the last
line) (see [1]).

No longer include the line number, as it is not stable accross Python versions.

If you really care, you can set NM_TEST_WITH_LINENO to get the line numbers back.
Of course, then the expected output won't match anymore, and you'd have to regenerate
it first. This is only useful if you debug tests, and want to have it easier to
correlate output with the tests while developing them.

[1] https://bugs.python.org/issue38283

https://gitlab.freedesktop.org/NetworkManager/NetworkManager/merge_requests/292
2019-09-26 19:31:56 +02:00
..
cli cli: add kill switch indication to "nmcli" output 2019-09-20 12:49:21 +02:00
common cli: add kill switch indication to "nmcli" output 2019-09-20 12:49:21 +02:00
tests clients/tests: don't include the source line number with client tests output 2019-09-26 19:31:56 +02:00
tui tui: wifi: support WPA3-Personal (SAE) 2019-09-20 13:18:19 +02:00
meson.build build/meson: rename "nm_core_dep" to "libnm_core_dep" 2019-04-18 18:59:09 +02:00
nm-online.c all: SPDX header conversion 2019-09-10 11:19:56 +02:00