File: //opt/alt/python27/lib/python2.7/site-packages/jsonschema/tests/test_format.pyo
�
���Xc           @   se   d  Z  d d l m Z m Z d d l m Z m Z m Z d d l m	 Z	 d e j
 f d �  �  YZ d S(   sQ   
Tests for the parts of jsonschema related to the :validator:`format` property.
i����(   t   mockt   unittest(   t   FormatErrort   ValidationErrort
   FormatChecker(   t   Draft4Validatort   TestFormatCheckerc           B   sG   e  Z d  �  Z d �  Z d �  Z d �  Z d �  Z d �  Z d �  Z RS(   c         C   s   t  j �  |  _ d  S(   N(   R    t   Mockt   fn(   t   self(    (    sM   /opt/alt/python27/lib/python2.7/site-packages/jsonschema/tests/test_format.pyt   setUp
   s    c         C   s#   t  d d � } |  j | j � d  S(   Nt   formats(    (   R   t   assertFalset   checkers(   R	   t   checker(    (    sM   /opt/alt/python27/lib/python2.7/site-packages/jsonschema/tests/test_format.pyt   test_it_can_validate_no_formats   s    c         C   s*   |  j  t � � t d d g � Wd  QXd  S(   NR   s   o noes(   t   assertRaisest   KeyErrorR   (   R	   (    (    sM   /opt/alt/python27/lib/python2.7/site-packages/jsonschema/tests/test_format.pyt.   test_it_raises_a_key_error_for_unknown_formats   s    c      	   C   s_   t  j j t j d t ��>