Uname : Linux premium36.web-hosting.com 4.18.0-553.44.1.lve.el8.x86_64 #1 SMP Thu Mar 13 14:29:12 UTC 2025 x86_64
Soft : LiteSpeed
Ip : 198.54.115.237
Port : 443
~
/
opt
/
alt
/
python37
/
lib
/
python3.7
/
site-packages
/
jsonschema
/
tests
/
__pycache__
[ HOME ]
Exec
Submit
test_exceptions.cpython-37.opt-1.pyc
B �pSe�; � @ s� d dl mZ d dlZd dlmZmZ d dlmZ G dd� de�ZG dd� de�Z G d d � d e�Z G dd� de�ZG d d� de�ZdS )� )�TestCaseN)�Draft4Validator� exceptions)�PY3c @ sT e Zd Zdd� Zdd� Zdd� Zdd� Zd d � Zdd� Zd d� Z dd� Z dd� ZdS )� TestBestMatchc C sH t |�}t�|�}t�t|��}d}| j|�� |�� |�||�d� |S )Nz:Didn't return a consistent best match! Got: {0} Then: {1})�msg)�listr � best_match�reversed�assertEqualZ _contents�format)�self�errors�bestZ reversed_bestr � r �Q/opt/alt/python37/lib/python3.7/site-packages/jsonschema/tests/test_exceptions.pyr s zTestBestMatch.best_matchc C sH t ddddddiid�ii�}| �|�ddg ii��}| �|jd� d S ) N� properties�foo� �bar�type�object)� minPropertiesr r )r r �iter_errorsr � validator)r r r r r r �(test_shallower_errors_are_better_matches s z6TestBestMatch.test_shallower_errors_are_better_matchesc C sJ t dddiddigddiddigd��}| �|�i ��}| �|jd� dS )zn A property you *must* match is probably better than one you have to match a part of. r r �stringZnumber)r �anyOf�oneOfr N)r r r r r )r r r r r r �%test_oneOf_and_anyOf_are_weak_matches"