diff options
| author | Sebastien Bacher <seb128@ubuntu.com> | 2019-01-25 11:24:41 +0100 |
|---|---|---|
| committer | Sebastien Bacher <seb128@ubuntu.com> | 2019-01-25 11:24:41 +0100 |
| commit | bbae86d3d2997a853ca0365e8eb7a3ca7489ee09 (patch) | |
| tree | 1f7fa49b47ab13aea3effbe839559d221f6323b4 /clients/tests/test-client.py | |
| parent | 404ebe62622150e77e311777dff8617eb974e834 (diff) | |
New upstream version 1.15.2
Diffstat (limited to 'clients/tests/test-client.py')
| -rwxr-xr-x | clients/tests/test-client.py | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/clients/tests/test-client.py b/clients/tests/test-client.py index e8f1f7f2..fee874ba 100755 --- a/clients/tests/test-client.py +++ b/clients/tests/test-client.py @@ -7,7 +7,7 @@ from __future__ import print_function # This test starts NetworkManager stub service in a user D-Bus session, # and runs nmcli against it. The output is recorded and compared to a pre-generated # expected output (clients/tests/test-client.check-on-disk/*.expected) which -# is also commited to git. +# is also committed to git. # ############################################################################### # @@ -27,7 +27,7 @@ from __future__ import print_function # # $ LANG=pl_PL.UTF-8 ./clients/cli/nmcli --version # # also ensure that `locale -a` reports the Polish locale. # $ rm -rf clients/tests/test-client.check-on-disk/*.expected -# # (step seldomly required) +# # (step seldom required) # # Sometimes, if you want to be sure that the test would generate # # exactly the same .expected files, purge the previous version first. # # This is only necessary, when you remove test from this file. @@ -744,10 +744,11 @@ class TestNmcli(NmTestBase): skip_test_for_l10n_diff.append(n['test_name']) continue print("\n\n\nThe file '%s' does not have the expected content:" % (filename)) - print("ACTUAL OUTPUT:\n[[%s]]\n" % (results_expect[i])) - print("EXPECT OUTPUT:\n[[%s]]\n" % (n['content'])) + print("ACTUAL OUTPUT:\n[[%s]]\n" % (n['content'])) + print("EXPECT OUTPUT:\n[[%s]]\n" % (results_expect[i])) print("Let the test write the file by rerunning with NM_TEST_REGENERATE=1") print("See howto in %s for details.\n" % (PathConfiguration.canonical_script_filename())) + sys.stdout.flush() self.fail("Unexpected output of command, expected %s. Rerun test with NM_TEST_REGENERATE=1 to regenerate files" % (filename)) if len(results_expect) != len(results): if not regenerate: @@ -758,6 +759,7 @@ class TestNmcli(NmTestBase): print("EXPECT OUTPUT:\n[[%s]]\n" % (results_expect[len(results)])) print("Let the test write the file by rerunning with NM_TEST_REGENERATE=1") print("See howto in %s for details.\n" % (PathConfiguration.canonical_script_filename())) + sys.stdout.flush() self.fail("Unexpected output of command, expected %s. Rerun test with NM_TEST_REGENERATE=1 to regenerate files" % (filename)) if regenerate: |