diff options
author | Wojciech Wypior <w.wypior@f5.com> | 2019-08-02 13:29:40 -0700 |
---|---|---|
committer | Tim Rupp <caphrim007@gmail.com> | 2019-08-02 13:29:40 -0700 |
commit | c9a9621a022fb6af476a3a4e3353f188c367e047 (patch) | |
tree | 376cecd3c41049759485af2a5c3c103f32665b75 /test/units/modules/network/f5 | |
parent | 6e8798fa8853629ee274fa15d957a71909fbf57f (diff) | |
download | ansible-c9a9621a022fb6af476a3a4e3353f188c367e047.tar.gz |
fixes issue with recieve parameter idempotency (#59999)
fixes assert statements in unit tests
Diffstat (limited to 'test/units/modules/network/f5')
4 files changed, 6 insertions, 6 deletions
diff --git a/test/units/modules/network/f5/test_bigip_device_connectivity.py b/test/units/modules/network/f5/test_bigip_device_connectivity.py index 3950199b63..d0398badbd 100644 --- a/test/units/modules/network/f5/test_bigip_device_connectivity.py +++ b/test/units/modules/network/f5/test_bigip_device_connectivity.py @@ -292,7 +292,7 @@ class TestManager(unittest.TestCase): with pytest.raises(F5ModuleError) as ex: mm.exec_module() - assert 'must be between' in str(ex) + assert 'must be between' in str(ex.value) def test_set_multicast_address(self, *args): set_module_args(dict( diff --git a/test/units/modules/network/f5/test_bigip_gtm_wide_ip.py b/test/units/modules/network/f5/test_bigip_gtm_wide_ip.py index 4f872f91cc..348a43dba2 100644 --- a/test/units/modules/network/f5/test_bigip_gtm_wide_ip.py +++ b/test/units/modules/network/f5/test_bigip_gtm_wide_ip.py @@ -120,7 +120,7 @@ class TestParameters(unittest.TestCase): with pytest.raises(F5ModuleError) as excinfo: p = ModuleParameters(params=args) assert p.name == 'foo' - assert 'The provided name must be a valid FQDN' in str(excinfo) + assert 'The provided name must be a valid FQDN' in str(excinfo.value) class TestUntypedManager(unittest.TestCase): diff --git a/test/units/modules/network/f5/test_bigip_monitor_http.py b/test/units/modules/network/f5/test_bigip_monitor_http.py index 70e237d124..93d57e2572 100644 --- a/test/units/modules/network/f5/test_bigip_monitor_http.py +++ b/test/units/modules/network/f5/test_bigip_monitor_http.py @@ -305,7 +305,7 @@ class TestManager(unittest.TestCase): with pytest.raises(F5ModuleError) as ex: mm.exec_module() - assert "must be less than" in str(ex) + assert "must be less than" in str(ex.value) def test_update_interval_larger_than_new_timeout(self, *args): set_module_args(dict( @@ -335,7 +335,7 @@ class TestManager(unittest.TestCase): with pytest.raises(F5ModuleError) as ex: mm.exec_module() - assert "must be less than" in str(ex) + assert "must be less than" in str(ex.value) def test_update_send(self, *args): set_module_args(dict( diff --git a/test/units/modules/network/f5/test_bigip_monitor_https.py b/test/units/modules/network/f5/test_bigip_monitor_https.py index 6e21ad11ca..700806f803 100644 --- a/test/units/modules/network/f5/test_bigip_monitor_https.py +++ b/test/units/modules/network/f5/test_bigip_monitor_https.py @@ -305,7 +305,7 @@ class TestManager(unittest.TestCase): with pytest.raises(F5ModuleError) as ex: mm.exec_module() - assert "must be less than" in str(ex) + assert "must be less than" in str(ex.value) def test_update_interval_larger_than_new_timeout(self, *args): set_module_args(dict( @@ -335,7 +335,7 @@ class TestManager(unittest.TestCase): with pytest.raises(F5ModuleError) as ex: mm.exec_module() - assert "must be less than" in str(ex) + assert "must be less than" in str(ex.value) def test_update_send(self, *args): set_module_args(dict( |