rdobuilder 23dcc2
--- a/dev-requirements.txt
rdobuilder 23dcc2
+++ b/dev-requirements.txt
rdobuilder 23dcc2
@@ -2,7 +2,6 @@
rdobuilder 23dcc2
 invoke>=2.0
rdobuilder 23dcc2
 invocations>=3.2
rdobuilder 23dcc2
 # Testing!
rdobuilder 23dcc2
-pytest-relaxed>=2
rdobuilder 23dcc2
 # pytest-xdist for test dir watching and the inv guard task
rdobuilder 23dcc2
 pytest-xdist>=3
rdobuilder 23dcc2
 # Linting!
rdobuilder 23dcc2
--- a/tests/test_client.py
rdobuilder 23dcc2
+++ b/tests/test_client.py
rdobuilder 23dcc2
@@ -33,7 +33,6 @@ import weakref
rdobuilder 23dcc2
 from tempfile import mkstemp
rdobuilder 23dcc2
 
rdobuilder 23dcc2
 import pytest
rdobuilder 23dcc2
-from pytest_relaxed import raises
rdobuilder 23dcc2
 from unittest.mock import patch, Mock
rdobuilder 23dcc2
 
rdobuilder 23dcc2
 import paramiko
rdobuilder 23dcc2
@@ -799,11 +798,11 @@ class PasswordPassphraseTests(ClientTest
rdobuilder 23dcc2
 
rdobuilder 23dcc2
     # TODO: more granular exception pending #387; should be signaling "no auth
rdobuilder 23dcc2
     # methods available" because no key and no password
rdobuilder 23dcc2
-    @raises(SSHException)
rdobuilder 23dcc2
     @requires_sha1_signing
rdobuilder 23dcc2
     def test_passphrase_kwarg_not_used_for_password_auth(self):
rdobuilder 23dcc2
-        # Using the "right" password in the "wrong" field shouldn't work.
rdobuilder 23dcc2
-        self._test_connection(passphrase="pygmalion")
rdobuilder 23dcc2
+        with pytest.raises(SSHException):
rdobuilder 23dcc2
+            # Using the "right" password in the "wrong" field shouldn't work.
rdobuilder 23dcc2
+            self._test_connection(passphrase="pygmalion")
rdobuilder 23dcc2
 
rdobuilder 23dcc2
     @requires_sha1_signing
rdobuilder 23dcc2
     def test_passphrase_kwarg_used_for_key_passphrase(self):
rdobuilder 23dcc2
@@ -823,15 +822,15 @@ class PasswordPassphraseTests(ClientTest
rdobuilder 23dcc2
             password="television",
rdobuilder 23dcc2
         )
rdobuilder 23dcc2
 
rdobuilder 23dcc2
-    @raises(AuthenticationException)  # TODO: more granular
rdobuilder 23dcc2
     @requires_sha1_signing
rdobuilder 23dcc2
     def test_password_kwarg_not_used_for_passphrase_when_passphrase_kwarg_given(  # noqa
rdobuilder 23dcc2
         self,
rdobuilder 23dcc2
     ):
rdobuilder 23dcc2
         # Sanity: if we're given both fields, the password field is NOT used as
rdobuilder 23dcc2
         # a passphrase.
rdobuilder 23dcc2
-        self._test_connection(
rdobuilder 23dcc2
-            key_filename=_support("test_rsa_password.key"),
rdobuilder 23dcc2
-            password="television",
rdobuilder 23dcc2
-            passphrase="wat? lol no",
rdobuilder 23dcc2
-        )
rdobuilder 23dcc2
+        with pytest.raises(AuthenticationException):
rdobuilder 23dcc2
+            self._test_connection(
rdobuilder 23dcc2
+                key_filename=_support("test_rsa_password.key"),
rdobuilder 23dcc2
+                password="television",
rdobuilder 23dcc2
+                passphrase="wat? lol no",
rdobuilder 23dcc2
+            )