+
     h-  c            
       s   ^ RI t ^ RIHtHtHt ^ RIt] P                  P                  RR]P                  P                  3R]P                  P                  3R]P                  P                  3R]P                  P                  3R]P                  P                  3R	]P                  P                  3.4      R
 4       tR t] P                  P                  RR]P                  P                  3R]P                  P                  3R]P                  P                  3R]P                  P                  3R]P                  P                  3R]P                  P                  3.4      R 4       t] P                  P                  R]P                  P                  ]P                  P                  ]P                  P                  ]P                  P                  .4      ] P                  P                  RRR.4      R 4       4       t] P                  P                  R]P                  P                  ]P                  P                  ]P                  P                  ]P                  P                  .4      ] P                  P                  RRR.4      R 4       4       t] P                  P                  R]P                  P                  ]P                  P                  ]P                  P                  ]P                  P                  .4      ] P                  P                  RRR.4      R 4       4       t] P                  P                  RR]P                  P                  3R]P                  P                  3R]P                  P                  3R]P                  P                  3R]P                  P                  3R	]P                  P                  3.4      R 4       t] P                  P                  RR]P                  P                  3R]P                  P                  3R]P                  P                  3R]P                  P                  3.4      R 4       tR tR tR tR  tR! tR" tR# tR$ tR% tR& t R# )'i    N)RegistryResourceSpecificationzuri, expectedz,https://json-schema.org/draft/2020-12/schemaz,https://json-schema.org/draft/2019-09/schemaz'http://json-schema.org/draft-07/schema#z'http://json-schema.org/draft-06/schema#z'http://json-schema.org/draft-04/schema#z'http://json-schema.org/draft-03/schema#c                s`    RV /p\         P                  ! V4      pV\        W!R7      8X  g   Q hR# )z=
The $schema keyword in JSON Schema is a dialect identifier.
$schema)contentsspecificationN)r   from_contents)uriexpectedr   Zresources   &&  F/usr/lib/python3.14/site-packages/referencing/tests/test_jsonschema.py7test_schemas_with_explicit_schema_keywords_are_detectedr
      s2    B 3H%%h/HxJJJJ    c                  s   R p \         P                  ! \        P                  P                  4      ;_uu_ 4       p\
        P                  ! RV /4       RRR4       XP                  P                  V 8X  g   Q hR#   + '       g   i     L/; i)1http://example.com/unknown-json-schema-dialect-idr   N)	pytestraisesreferencing
jsonschemaUnknownDialectr   r   valuer   
dialect_idZexcinfo     r	   test_unknown_dialectr   -   s]    DJ	{--<<	=	=	:67 
>==
*** 
>	=s   A99B		zid, specification$ididc                 s<    R pVP                  W/4      V8X  g   Q hR# )zhttp://example.com/some-schemaNZid_of)r   r   r   s   && r	   test_id_of_mappingr   4   s$     +Cy)S000r   r   r   TFc                 s0    V P                  V4      e   Q hR # Nr   r   r      &&r	   test_id_of_boolr   D   s     u%---r   c                 H    \        V P                  V4      4      . 8X  g   Q hR # r   )listZ
anchors_inr   r   r	   test_anchors_in_boolr!   R   s"     ((/0B666r   c                 r   r   )r    Zsubresources_ofr   r   r	   test_subresources_of_boolr"   `   s"     --e45;;;r   c                 R    \         P                  P                  V 4      V8X  g   Q hR # r   r   r   specification_withr   r   r   r	   test_specification_withr'   n   s#    < !!44S9XEEEr   z&http://json-schema.org/draft-07/schemaz&http://json-schema.org/draft-06/schemaz&http://json-schema.org/draft-04/schemaz&http://json-schema.org/draft-03/schemac                 r#   r   r$   r&   r   r	   )test_specification_with_no_empty_fragmentr(      s#    , !!44S9XEEEr   c                  s&   R p \         P                  ! \        P                  P                  4      ;_uu_ 4       p\        P                  P                  V 4       RRR4       XP                  P                  V 8X  g   Q hR#   + '       g   i     L/; i)r   N)r   r   r   r   r   r%   r   r   r   r   r	   'test_specification_with_unknown_dialectr)      s^    DJ	{--<<	=	=11*= 
>==
*** 
>	=s    B  B	c                  s    R p \         P                  P                  V \        P                  R7      pV\        P                  J g   Q hR# )r   )ZdefaultN)r   r   r%   r   ZOPAQUE)r   r   r   r	   test_specification_with_defaultr*      sD    DJ**==$$ > M M00000r   c                  s   \         P                  P                  P                  R R/4      p \	        4       P                  RV 4      P                  4       pVP                  R4      pVP                  V P                  8X  g   Q hR# )$dynamicAnchorfoohttp://example.comzhttp://example.com#fooN)	r   r   DRAFT202012create_resourcer    with_resourceresolverlookupr   )oner1   resolved      r	   test_lookup_trivial_dynamic_refr6      sm    

 
 
,
,
<
<	5!C z''(<cBKKMH78H,,,r   c                  s0   \         P                  P                  P                  R 4      p \         P                  P                  P                  RRRRRRRRRRRRR RRR/////4      p\	        4       P                  RV3R	V 3R
V3.4      P                  4       pVP                  R4      pVP                  P                  R4      pVP                  P                  R4      P                  pVP                  R4      pVP                  VP                  8X  g   Q hR# )Tr   r-   r+   	fooAnchor$defsr,   barbazhttp://example.com/foo/http://example.com/foo/barfoo/
#fooAnchorN	r   r   r.   r/   r    with_resourcesr1   r2   r   TRUEZrootr1   firstsecondfourth         r	   (test_multiple_lookup_trivial_dynamic_refrG      s   !!--==dCD!!--=='k5$kt,k 		
D& 	
	%t,*D1-t4

 
  OO01E^^""6*F%%e,55H__\*F??dmm+++r   c                  s4   \         P                  P                  P                  R R/4      p \         P                  P                  P                  RRRRRRRRRRRRRR	RR/////4      p\	        4       P                  RV3R
V 3RV3.4      P                  4       pVP                  R4      pVP                  P                  R4      pVP                  P                  R4      P                  pVP                  R4      pVP                  VP                  8X  g   Q hR# )$anchorr7   r   r-   r+   r8   r,   r9   Tr:   r;   r<   r=   r>   Nr?   )r3   twor1   rC   rD   rE   rF   r	   2test_multiple_lookup_dynamic_ref_to_nondynamic_refrJ      s'   

 
 
,
,
<
<	K C 
 
 
,
,
<
<'k5$kt,k 		
C& 	
	%s+*C0-s3

 
  OO01E^^""6*F%%e,55H__\*F??cll***r   c                  s\   \         P                  P                  P                  R R/4      p \	        4       P                  RV 4      P                  4       pVP                  R4      p\         P                  P                  VP                  R7      pVP                  V P                  8X  g   Q hR# )$recursiveAnchorTr-   r1   N)
r   r   DRAFT201909r/   r    r0   r1   r2   lookup_recursive_refr   )r3   r1   rC   r4   s       r	   !test_lookup_trivial_recursive_refrO     s    

 
 
,
,
<
<	T"C z''(<cBKKMHOO01E%%:: ; H ,,,r   c                  s   \         P                  P                  P                  R 4      p \	        RV /4      p\         P                  P                  VP                  RR7      R7      pVP                  V P                  8X  g   Q hR# )Tr-   )Zbase_urirL   N)r   r   rM   r/   r    rN   r1   r   )rB   Zregistryr4   r5   r	   !test_lookup_recursive_ref_to_boolrP     su    !!--==dCD-t45H%%::"",@"A ; H ---r   c                  sR   \         P                  P                  P                  R 4      p \         P                  P                  P                  RRRR RRRRRR RRR RRR RR	/////4      p\	        4       P                  RV3R
V 3RV3.4      P                  4       pVP                  R4      pVP                  P                  R4      pVP                  P                  R4      P                  p\         P                  P                  VR7      pVP                  VP                  8X  g   Q hR# )Tr   r-   rK   r8   r,   r9   r:   rH   r7   r;   r<   r=   rL   N
r   r   rM   r/   r    r@   r1   r2   rN   r   rA   rF   r	   *test_multiple_lookup_recursive_ref_to_boolrR   (  s-   !!--==dCD!!--=='5&t.%{ 
	
D( 	
	%t,*D1-t4

 
  OO01E^^""6*F%%e,55H##88(8KF??dmm+++r   c                  s   \         P                  P                  P                  R R/4      p \         P                  P                  P                  RRR RRRRRR RRRRRR RRR	/////4      p\         P                  P                  P                  R R
/4      p\	        4       P                  RV3RV3RV 3.4      P                  4       pVP                  R4      pVP                  P                  R4      pVP                  P                  R4      P                  p\         P                  P                  VR7      pVP                  VP                  8X  g   Q hR# )rK   Tr   r-   r8   r,   r9   r:   rH   r7   Fr;   r<   r=   rL   NrQ   )r3   rI   Zthreer1   rC   rD   rE   s          r	   8test_multiple_lookup_recursive_ref_with_nonrecursive_refrS   P  s]   

 
 
,
,
<
<	T"C 
 
 
,
,
<
<'5&t.%{ 
	
C& ""..>>	U#E 	
	%u-*C0-s3

 
  OO01E^^""6*F%%e,55H##88(8KF??cll***r   c                  sX    \         P                  P                  \        4       8X  g   Q hR # r   )r   r   ZEMPTY_REGISTRYr     r   r	   test_empty_registryrU   }  s    !!00HJ>>>r   )!r   r   r    r   r   Zreferencing.jsonschemaZmarkZparametrizer   r.   rM   ZDRAFT7ZDRAFT6ZDRAFT4ZDRAFT3r
   r   r   r   r!   r"   r'   r(   r)   r*   r6   rG   rJ   rO   rP   rR   rS   rU   rT   r   r	   <module>rV      s    9 9   ;""..	

 ;""..	

 6""))	

 6""))	

 6""))	

 6""))	
+:K;:K+ 	&&223	&&223	&&--.	&&--.	{%%,,-	{%%,,-
1
1
 ****%%%%	 4-0. 1. ****%%%%	 4-07 17 ****%%%%	 4-0< 1<  ;""..	

 ;""..	

 6""))	

 6""))	

 6""))	

 6""))	
+:F;:F  5""))	

 5""))	

 5""))	

 5""))	
*F+*F+1-$,N&+R	-.%,P*+Z?r   