
    Mh	                        d dl mZ d dlZd dlZd dlZd dlmZ d dlmZ d dl	Z G d de
          Zdej        v r eej        d                   dz  Zn ee          j        j        j        d	z  Ze                                s
 e             ej        e                    d
                                                    Zej                            dd e                    d          D                       d             ZdS )    )PathN)Registry)Unresolvablec                       e Zd Zd ZdS )SuiteNotFoundc                     	 dS )NzCannot find the referencing suite. Set the REFERENCING_SUITE environment variable to the path to the suite, or run the test suite from alongside a full checkout of the git repository. )selfs    h/var/www/html/test/jupyter/venv/lib/python3.11/site-packages/referencing/tests/test_referencing_suite.py__str__zSuiteNotFound.__str__   s    %	
 	
    N)__name__
__module____qualname__r   r	   r   r   r   r      s#        
 
 
 
 
r   r   REFERENCING_SUITEtestszsuite/testszspecifications.json	test_pathc                 b    g | ],}t          j        ||j        j         d |j                   -S )-)id)pytestparamparentnamestem).0eachs     r   
<listcomp>r   !   sL        	T!1??DI??@@@  r   z*/**/*.jsonc                   	 t           |                     t                    j        d                  }t          j                            |          	t          j        | 	                                          }|d         }t                                          	fd|d                                         D                       }|d         D ]}|                    |          5  d| j        v rt          j        d           |                    |                    dd	          
          }|                    d          rMt          j        t(                    5  |                    |d                    d d d            n# 1 swxY w Y   n|                    |d                   }|j        |d         k    sJ |                    d          }|rz|                    ||          5  |j                            |d                   }|j        |d         k    sJ 	 d d d            n# 1 swxY w Y   |                    d          }|zd d d            n# 1 swxY w Y   d S )Nr   registryc              3   L   K   | ]\  }}|                     |          fV  d S )N)create_resource)r   uricontentsspecifications      r   	<genexpr>z)test_referencing_suite.<locals>.<genexpr>+   sN       ) )C 
m++H556) ) ) ) ) )r   r   )testnormalizationz+APIs need to change for proper URL support.base_uri )r)   errorreftargetthen)r'   r.   )DIALECT_IDSrelative_toSUITEpartsreferencing
jsonschemaspecification_withjsonloads	read_textr   with_resourcesitemsr'   r   r   xfailresolvergetraisesr   lookupr$   )
r   subtests
dialect_idloadedr    r'   r<   resolvedr.   r%   s
            @r   test_referencing_suiterD      s!    Y22599?BCJ*==jIIMZ	++--..Fj!Hzz(( ) ) ) )#J/5577) ) )  H w , ,]]]%% 	, 	,).00JKKK(($((:r2J2J(KKHxx   ,]<00 1 1OODK0001 1 1 1 1 1 1 1 1 1 1 1 1 1 1 $??4;77(DN::::xx'' ,!Dt<< C C#+#4#;#;DK#H#H'0DNBBBBBC C C C C C C C C C C C C C C  88F++D	  ,	, 	, 	, 	, 	, 	, 	, 	, 	, 	, 	, 	, 	, 	, 	,, ,s\   %A6IF7IFI
FA I+4H, I,H00I3H04II	!I	)pathlibr   r6   osr   r3   r   referencing.exceptionsr   referencing.jsonschema	Exceptionr   environr1   __file__r   is_dirr7   joinpathr8   r/   markparametrizeglobrD   r	   r   r   <module>rQ      s          				              / / / / / /    
 
 
 
 
I 
 
 
 "*$$D/011G;EEDNN!(/-?E||~~ 
-//dj(=>>HHJJKK  JJ}--   , , , , ,r   