aboutsummaryrefslogtreecommitdiffstats
path: root/tests/utils.py
diff options
context:
space:
mode:
authorAlex Gaynor <alex.gaynor@gmail.com>2013-12-27 08:22:07 -0800
committerAlex Gaynor <alex.gaynor@gmail.com>2013-12-27 08:22:07 -0800
commit4b31af7407ab6221712e8d83cd1bce53bd57aa95 (patch)
tree7b6774bc8559f51b47cb3510c244146ce20d00fb /tests/utils.py
parent3ac297e4c9b655b3222da1830e9677c9d03a3926 (diff)
parent37c88a0dea800b3028f95bf71a8cd6e344254d4e (diff)
downloadcryptography-4b31af7407ab6221712e8d83cd1bce53bd57aa95.tar.gz
cryptography-4b31af7407ab6221712e8d83cd1bce53bd57aa95.tar.bz2
cryptography-4b31af7407ab6221712e8d83cd1bce53bd57aa95.zip
Merge branch 'master' into fernet
Diffstat (limited to 'tests/utils.py')
-rw-r--r--tests/utils.py12
1 files changed, 11 insertions, 1 deletions
diff --git a/tests/utils.py b/tests/utils.py
index 94f97d59..82021a5f 100644
--- a/tests/utils.py
+++ b/tests/utils.py
@@ -11,7 +11,17 @@
# See the License for the specific language governing permissions and
# limitations under the License.
-import os.path
+import os
+
+import pytest
+
+
+def check_for_iface(name, iface, item):
+ if name in item.keywords and "backend" in item.funcargs:
+ if not isinstance(item.funcargs["backend"], iface):
+ pytest.skip("{0} backend does not support {1}".format(
+ item.funcargs["backend"], name
+ ))
def load_vectors_from_file(filename, loader):