
    ~/jh                   	   S SK Jr  S SKrS SKJr  S SKJr  S SKJr  S SKJr  S SKJ	r	  S SKJ
r
  S S	KJr  S S
KJr  S SKJr  S SKJr  S SKJr  S SKrS SKrS SKrS SKrS SKJr  S SKrS SKrS SKJr  S SKJr  S SKJr  S SKJr  S SKJr  S SKJr  S SKJ r   S SKJ!r!  S SKJ"r"  S SKJ#r#  S SK$r$S SK%r%S SK%J&r&  S SK'J(r(  S SK'J)r)  S SK*J+r+  S SK*J,r,  S SK-J.r.  S SK/J0r0  S S K/J1r1  S S!K/J2r2  S S"K/J3r3  S S#K/J4r4  S S$K/J5r5  S S%K/J6r6  S S&K/J7r7  S S'K/J8r8  S S(K/J9r9  S S)K/J:r:  S S*K;J<r<  S S+K;J=r=  S S,K;J>r>  S S-K;J?r?  S S.K@JArA  S S/KBJCrC  S S0KBJDrD  S S1KBJErE  S S2KBJFrF  S S3KBJGrG  S S4KBJHrH  S S5KBJIrI  S S6KBJJrJ  S S7KKJLrL  S S8KMJNrN  S S9KOJPrP  S S:KQJRrR  S S;KQJSrS  S S<KQJTrT  S S=KUJVrV  S S>KUJWrW  S S?KXJYrY  S S@KXJZrZ  S SAKXJ[r[  S SBK\J]r]  \R                  SC:  a  S SDK_J`r`  \"(       a  S SEKaJbrb  S SFKaJcrc  S SGKaJdrd  S SHKeJfrf  \#" SISJSK9rg\SL\h4   ri\SL\g4   \SL\	\g   4   -  rj\k\g\hS4   \kS\h\k\l\R                  S-  4   4   -  rnSSN jro      SSO jrp      SSP jrqSSQ jrrSSR jrs\R                  " SJSS9 " ST SU5      5       ru\#" SV5      rv\w\vS4   rxSSW jrySSX jrz          SSY jr{      SSZ jr|\R                  " SJSS9 " S[ S\5      5       r} " S] S^\R                  5      r\ " S_ S`\5      5       r\ " Sa Sb\5      5       r\ " Sc Sd\5      5       r " Se Sf\,5      r      SSg jrSSh jr        SSi jr " Sj Sk\\g   5      r " Sl Sm\\   5      r      SSn jr      SSo jr\\R                  " SJSS9 " Sp Sq5      5       5       r " Sr Ss5      r\!SLSLSLSLSLSt.             SSu jj5       r\! SSLSLSLSLSSt.             SSv jjj5       r SSwSSxSSSt.             SSy jjjr\1" SzSS{9 SSwSSxSSSt.S| jj5       r\" SMS}9SS~ j5       rSS jrSS jr        SS jrSS jrSS jr " S S5      rSS jr\" \%GR0                  5      GR2                  rSS jrSS jrSS jrSS jrSS jrSSS jjrSwSSSxS.               SS jjrg)    )annotationsN)defaultdict)deque)OrderedDict)Callable)	Generator)Iterable)Iterator)Mapping)MutableMapping)Sequence)Set)Path)Any)cast)Final)final)Generic)Literal)NoReturn)overload)TYPE_CHECKING)TypeVar)nodes)getfslineno)Source)ExceptionInfoFormatter)TerminalRepr)TerminalWriter)assert_never)
deprecated)get_real_func)getfuncargnames)	getimfunc)getlocation)NOTSET)
NotSetType)safe_getattr)safe_isclass)	signature)_PluggyPlugin)Config)ExitCode)hookimpl)Parsercheck_ispytest)CLASS_FIXTURE_INSTANCE_METHOD)FIXTURE_BASEID_DEPRECATED)'FIXTURE_GETFIXTUREVALUE_DURING_TEARDOWN)FIXTURE_NODEID_DEPRECATED)"FIXTUREDEF_HAS_LOCATION_DEPRECATED) PARSEFACTORIES_NODEID_DEPRECATED)YIELD_FIXTURE)Session)ParameterSet)MarkDecorator)fail)skip)TEST_OUTCOME)absolutepath)bestrelpath)HIGH_SCOPES)Scope)	ScopeName)PytestWarning)      )BaseExceptionGroup)	CallSpec2)Function)Metafunc)CollectReportFixtureValueT)	covariant.sessionc                $    [        U 5      U l        g N)FixtureManager_fixturemanager)rN   s    O/root/lseg-credit/backend/venv/lib/python3.13/site-packages/_pytest/fixtures.pypytest_sessionstartrT   t   s    ,W5G    c                    SSK Jn  U R                  5        HU  n[        X25      (       d  M  UR                  b  X1R                  :X  a  Us  $ M7  UR
                  UR                  :X  d  MS  Us  $    U R                  $ )Nr   )Package)_pytest.pythonrW   iter_parents
isinstancenodenodeidbaseidrN   )r[   
fixturedefrW   parents       rS   get_scope_packager`   x   sh     '##%f&&*__,!M - ==J$5$55!M & <<rU   c                   U R                   b  UR                   c}  U R                  UR                  :X  a  gUR                  S:X  a  gU R                  R                  UR                  5      =(       a%    U R                  [        UR                  5         S;   $ U R                   UR                   L=(       a'    UR                   U R                   R	                  5       ;   $ )zReturn whether the visibility of ``candidate`` is strictly more specific
than that of ``other``, i.e. ``candidate`` is defined on a strict descendant
in the collection tree of where ``other`` is defined.F T)/:)r[   r]   
startswithlenrY   )	candidateothers     rS   is_visibility_more_specificri      s     ~~!3 u||+<<2 **5<<8 Y=M=M>
> 	
 	ejj(XUZZ9>>;V;V;X-XrU   c                F   SSK nU[        R                  L a  U R                  [        R
                  5      $ U[        R                  L a%  U R                  UR                  R                  5      $ U[        R                  L a%  U R                  UR                  R                  5      $ U[        R                  L a%  U R                  UR                  R                  5      $ U[        R                  L a%  U R                  UR                  R                  5      $ [        U5        g)zGet the closest parent node (including self) which matches the given
scope.

If there is no parent node for the scope (e.g. asking for class scope on a
Module, or on a Function when not defined in a class), returns None.
r   N)rX   rB   rI   	getparentr   ItemClasspythonModulerW   r9   mainr    )r[   scope_pytests      rS   get_scope_noders      s      ~~ejj))	%++	~~gnn2233	%,,	~~gnn3344	%--	~~gnn4455	%--	~~gll2233UrU   c                F    [        U [        5      (       a  U R                  $ g)z0Return fixturemarker or None if it doesn't existN)rZ   FixtureFunctionDefinition_fixture_function_marker)objs    rS   getfixturemarkerrx      s    #011+++rU   )frozenc                  B    \ rS rSr% SrS\S'   S\S'   S\S'   S	\S
'   Srg)ParamArgKey   zA key for a high-scoped parameter used by an item.

For use as a hashable key in `reorder_items`. The combination of fields
is meant to uniquely identify a particular "instance" of a param,
potentially shared by multiple items in a scope.
strargnameintparam_indexzPath | Nonescoped_item_pathtype | Noneitem_cls N)__name__
__module____qualname____firstlineno____doc____annotations____static_attributes__r   rU   rS   r{   r{      s"     L "!rU   r{   _Vc              #  .  #    U[         R                  Ld   e U R                  nSnU[         R                  L a  SnOU[         R
                  L a  U R                  R                  nOWU[         R                  L a  U R                  nO7U[         R                  L a  U R                  nU R                  nO[        U5        UR                   H6  nUR                  U   U:w  a  M  UR                  U   n[        XVWU5      v   M8     g! [         a     gf = f7f)zCReturn all ParamArgKeys for item matching the specified high scope.N)rB   rI   callspecAttributeErrorr9   rW   pathr_   ro   rm   clsr    indices
_arg2scoper{   )itemrq   r   r   r   r~   r   s          rS   get_param_argkeysr      s     &&&"mm H	%--	99++	%,,	99	%++	9988U##w'50&&w/'0@(KK	 $#  s(   DD C D
DDDDc                P   0 n0 n[          H`  n0 =oAU'   [        [        5      =oRU'   U  H>  n[        R	                  [        Xc5      5      nU(       d  M*  XtU'   U H
  nS XX   U'   M     M@     Mb     [        R	                  U 5      n	[        [        XU[        R                  5      5      $ rP   )
rA   r   r   dictfromkeysr   listreorder_items_atscoperB   r9   )
itemsargkeys_by_itemitems_by_argkeyrq   scoped_argkeys_by_itemscoped_items_by_argkeyr   argkeysargkey	items_sets
             rS   reorder_itemsr      s    NPOUWO:<<!7:Ek:RR!7Dmm$5d$BCGw/6t,%F;?*248 &	   e$I	
 rU   c                  ^ U[         R                  L d  [        U 5      S:  a  U $ X#   nX   n[        5       m[	        U 5      n0 nU(       Ga  0 nS n	U(       GaE  UR                  5       n
X;   d  X;   a  M$  [        R                  U4S jUR                  U
S5       5       5      nU(       d  S X'   OUR                  5       u  pXI    Vs/ s H  oU ;   d  M
  UPM     nn[        U5       H  nUR                  U5        [         H  nX/   nX   R                  US5       Hj  nUU   n[        [        S5      (       d  S UU'   UR                  USS9  M4  UR!                  5       nUR#                  5         S UU'   UR%                  U5        Ml     M     M     O
U(       a  GME  U(       a+  ['        XX#R)                  5       5      nUR%                  U5        U	b  TR+                  U	5        U(       a  GM  U$ s  snf )NrE   c              3  6   >#    U  H  oT;  d  M
  Uv   M     g 7frP   r   ).0kignores     rS   	<genexpr>(reorder_items_atscope.<locals>.<genexpr>+  s      $?aF??   		r   pypy_version_infoF)last)rB   rI   rf   setr   popleftr   r   getpopitemreversed
appendleftrA   hasattrsysmove_to_endcopyclearupdater   
next_loweradd)r   r   r   rq   r   r   items_deque
items_doneno_argkey_itemsslicing_argkeyr   r   _imatching_itemsother_scopeother_scoped_items_by_argkeyr   argkey_dictbkpreordered_no_argkey_itemsr   s                        @rS   r   r     s    #e*q.,3,3"uF,K)+J
24&&(D!T%<mm $155dB?$ G (,%$+OO$5!  6E"E!eAE  " ".1A**1-'27F7S4&5&B&F&Fq"&MF*Fv*NK#*30C#D#D15A + 7 7 7 F
 '2&6&6&8 + 1 1 315A + 2 23 7 'N (3 2$ E kF (=/CSCSCU)% 78%JJ~&Y +Z ;"s   	G0G0c             #  `   ^^^#    0 mSUUU4S jjmU  H  nT" U5       Sh  vN   M     g N	7f)zStatically traverse the fixture dependency closure in DFS order starting
from initialnames, yielding all requested fixture names (argnames).

Each argname is only yielded once.
c              3  (  >#    TR                  U 5      nUS:X  a  g Uc	  U v   STU '   T" U 5      nU(       d  g TR                  U S5      nU* [        U5      :  a  g X!   nUS-
  TU '   UR                   H  nT" U5       S h  vN   M     UTU '   g  N7f)N   )r   rf   argnames)r~   indexfixturedefsr^   depcurrent_indicesgetfixturedefsprocess_argnames        rS   r   1traverse_fixture_closure.<locals>.process_argnamee  s     ##G, B; =M')OG$$W-##GR06C$$ '
#(19 &&C&s+++ '#(  ,s   A>BBBN)r~   r}   returnIterator[str]r   )initialnamesr   r~   r   r   s    ` @@rS   traverse_fixture_closurer   T  s4      ')O) )6  "7+++  +s   .,
.c                  P    \ rS rSr% SrSrS\S'   S\S'   S\S'   S	\S
'   SS jrSrg)FuncFixtureInfoi  a  Fixture-related information for a fixture-requesting item (e.g. test
function).

This is used to examine the fixtures which an item requests statically
(known during collection). This includes autouse fixtures, fixtures
requested by the `usefixtures` marker, fixtures requested in the function
parameters, and the transitive closure of these.

An item may also request fixtures dynamically (using `request.getfixturevalue`);
these are not reflected here.
)r   r   name2fixturedefsnames_closuretuple[str, ...]r   r   	list[str]r   z$dict[str, Sequence[FixtureDef[Any]]]r   c                   ^ [        [        U R                  U R                  R                  S95      mU4S jU R
                   5       U R
                  SS& g)a  Recompute names_closure from initialnames and name2fixturedefs.

Can only reduce names_closure, which means that the new closure will
always be a subset of the old one. The order is preserved.

This method is needed because direct parametrization may shadow some
of the fixtures that were included in the originally built dependency
tree. In this way the dependency tree can get pruned, and the closure
of argnames may get reduced.
r   c              3  6   >#    U  H  oT;   d  M
  Uv   M     g 7frP   r   )r   nameclosures     rS   r   8FuncFixtureInfo.prune_dependency_tree.<locals>.<genexpr>  s      X2D$PW2Dr   N)r   r   r   r   r   r   )selfr   s    @rS   prune_dependency_tree%FuncFixtureInfo.prune_dependency_tree  sM     $!!#4488
 !Y$2D2D X1rU   r   Nr   None)	r   r   r   r   r   	__slots__r   r   r   r   rU   rS   r   r     s5    
 RI  "! 
 ;:YrU   r   c                     \ rS rSrSrSS.           SS jjr\S S j5       r\\R                  S!S j5       5       r
\S"S j5       r\R                        S#S	 j5       r\S$S
 j5       r\\R                  S 5       5       r\S%S j5       r\S 5       r\S 5       r\S 5       r\S 5       r\S&S j5       r\S'S j5       r\S(S j5       r\R                  S)S j5       rS*S jrS+S jrS,S jrS-S jrS.S jrS/S jrS0S jrS1S jrSr g)2FixtureRequesti  zThe type of the ``request`` fixture.

A request object gives access to the requesting test context and has a
``param`` attribute in case the fixture is parametrized.
F	_ispytestc               N    [        U5        X l        Xl        X0l        X@l        U   g rP   )r1   fixturename_pyfuncitem_arg2fixturedefs_fixture_defs)r   
pyfuncitemr   arg2fixturedefsfixture_defsr   s         rS   __init__FixtureRequest.__init__  s-     	y!"-", (7 %1 	rU   c                B    U R                   R                  R                  $ rP   )r   rN   rR   r   s    rS   rR   FixtureRequest._fixturemanager  s    ''777rU   c                    [        5       erP   NotImplementedErrorr   s    rS   _scopeFixtureRequest._scope  s     "##rU   c                .    U R                   R                  $ zIScope string, one of "function", "class", "module", "package", "session".r   valuer   s    rS   rq   FixtureRequest.scope       {{   rU   c                    [        5       erP   r   r   requested_fixturedefrequested_scopes      rS   _check_scopeFixtureRequest._check_scope  s     "##rU   c                    [        U R                  R                  5      nUR                  [	        U R
                  5      R                  U5      5        U$ )z-Names of all active fixtures in this request.)r   r   fixturenamesextendr   r   
difference)r   results     rS   r  FixtureRequest.fixturenames  sA     d&&334c$,,-88@ArU   c                    [        5       e)z>Underlying collection node (depends on current request scope).r   r   s    rS   r[   FixtureRequest.node       "##rU   c                .    U R                   R                  $ )z6The pytest config object associated with this request.)r   configr   s    rS   r  FixtureRequest.config  s     &&&rU   c                    U R                   S:w  a  [        SU R                    S35      eU R                  R                  $ )z=Test function object if the request has a per-function scope.functionzfunction not available in -scoped context)rq   r   r   rw   r   s    rS   r  FixtureRequest.function  sA     ::# ,TZZLH  ###rU   c                    U R                   S;  a  [        SU R                    S35      eU R                  R                  [        R
                  R                  5      nU(       a  UR                  $ g)z:Class (can be None) where the test function was collected.)classr  zcls not available in r  N)rq   r   r   rk   rr   rn   rm   rw   )r   clscols     rS   r   FixtureRequest.cls  s\     ::22 #8O!TUU!!++GNN,@,@A:: rU   c                R    U R                   S:w  a  g[        U R                  SS5      $ )z<Instance (can be None) on which test function was collected.r  Ninstance)rq   getattrr   r   s    rS   r!  FixtureRequest.instance  s(     ::#t''T::rU   c                    U R                   S;  a  [        SU R                    S35      eU R                  R                  [        R
                  R                  5      nUc   eUR                  $ )z;Python module object where the test function was collected.)r  r  modulezmodule not available in r  )rq   r   r   rk   rr   rn   ro   rw   )r   mods     rS   r%  FixtureRequest.module  s]     ::<< #;DJJ<!WXX(()>)>?wwrU   c                    U R                   S;  a  [        SU R                    S35      eU R                  R                  $ )z+Path where the test function was collected.)r  r  r%  packagezpath not available in r  )rq   r   r   r   r   s    rS   r   FixtureRequest.path&  s<     ::GG #9$**_!UVV$$$rU   c                2    U R                   nUR                  $ )z4Keywords/markers dictionary for the underlying node.)r[   keywords)r   r[   s     rS   r,  FixtureRequest.keywords-  s      99}}rU   c                .    U R                   R                  $ )zPytest session object.)r   rN   r   s    rS   rN   FixtureRequest.session3  s     '''rU   c                    [        5       e)zAdd finalizer/teardown function to be called without arguments after
the last test within the requesting test context finished execution.r   r   	finalizers     rS   addfinalizerFixtureRequest.addfinalizer8  r  rU   c                :    U R                   R                  U5        g)zApply a marker to a single test function invocation.

This method is useful if you don't want to have a keyword/marker
on all function invocations.

:param marker:
    An object created by a call to ``pytest.mark.NAME(...)``.
N)r[   
add_marker)r   markers     rS   applymarkerFixtureRequest.applymarker>  s     			V$rU   c                    [        SX5      e)zYRaise a FixtureLookupError exception.

:param msg:
    An optional custom error message.
NFixtureLookupError)r   msgs     rS   
raiseerrorFixtureRequest.raiseerrorI  s     !t11rU   c                &    SU S3n[        XU5      e)NThe fixture value for "a+  " is not available during teardown because it was not previously requested.
Only fixtures that were already active can be retrieved during teardown.
Request the fixture before teardown begins by declaring it in the fixture signature or by calling request.getfixturevalue() before the fixture yields.r;  )r   r~   r=  s      rS   _raise_teardown_lookup_error+FixtureRequest._raise_teardown_lookup_errorQ  s)    %gY /[ [ 	 !44rU   c                r    U R                  U5      nUR                  c   SU S35       eUR                  S   $ )a  Dynamically run a named fixture function.

Declaring fixtures via function argument is recommended where possible.
But if you can only decide whether to use another fixture at test
setup time, you may use this function to retrieve it inside a fixture
or test function body.

This method can be used during the test setup phase or the test run
phase. Avoid using it during the teardown phase.

.. versionchanged:: 9.1
    Calling ``request.getfixturevalue()`` during teardown to request a
    fixture that was not already requested
    :ref:`is deprecated <dynamic-fixture-request-during-teardown>`.

:param argname:
    The fixture name.
:raises pytest.FixtureLookupError:
    If the given fixture could not be found.
rA  zQ" is not available.  This can happen when the fixture has already been torn down.r   )_get_active_fixturedefcached_result)r   r~   r^   s      rS   getfixturevalueFixtureRequest.getfixturevalue[  sS    4 009
''3 	
%gY /K K	
3 ''**rU   c              #     #    U n[        U[        5      (       a(  Uv   UR                  n[        U[        5      (       a  M'  gg7f)zZYield all SubRequests in the chain, from self up.

Note: does *not* yield the TopRequest.
N)rZ   
SubRequest_parent_request)r   currents     rS   _iter_chainFixtureRequest._iter_chain|  s8     
 *--M--G *--s   =AAc           	        US:X  a  [        U 5      $ U R                  R                  U5      nUb  U R                  X"R                  5        U$ U R
                  R                  US 5      nUc%  U R                  R                  XR                  5      nUc  [        X5      eU(       d  [        X5      eSnU R                  5        H  nUR                  U:X  d  M  US-  nM     U* [        U5      :  a  [        X5      eX4   n U R                  R                  nUb=  XR                  ;   a.  UR                  U   nUR                   U   nUR"                  U   n	O%[$        nSnUR                  n	U R'                  U5        U R                  X"R                  5        [)        X	XxUSS9n
U R*                  R,                  R/                  U R0                  5      (       df  [2        R4                  " [6        R8                  " US9SS	9  U
R0                  U R*                  R,                  R:                  ;  a  U R=                  U5        UR?                  U
S
9  X R                  U'   U$ ! [         a    S n GNTf = f)Nrequestr   r   r   Tr   )r~   rE   
stacklevelrP  ) RequestFixtureDefr   r   r
  r   r   rR   r   r   r<  rM  r   rf   r   r   paramsr   r   r&   _check_fixturedef_without_paramrJ  rN   _setupstateis_node_activer[   warningswarnr4   formatstackrB  execute)r   r~   r^   r   r   rP  r   paramr   rq   
subrequests              rS   rE  %FixtureRequest._get_active_fixturedef  sJ   i$T** ''++G4
!j*;*;< ++//> ..==gGWGWXK$W33$W33 '')G""g-
 * 6C$$$W33 '
	''00H G$>OOG,E"**73K''0EEK%%E00< 	*&7&78Z4

 ||''66tyyAA MM7>>wO dll&>&>&D&DD11': 	:.&07#I  	H	s   I I,+I,c           
        U R                   nUR                  SLn[        USS5      nU(       aB  U(       a;  UR                   SUR                   S[        U5      R                   3n[        USS9  U(       a  [        R                  " 5       S   n[        R                  " US   5      n[        UR                  5      nUR                  n	 [        UR                  UR                   R"                  5      5      n
['        UR(                  UR                   R"                  5      nS	UR                   S
UR*                   SU SU
 SU	 3
n[        USS9  gg! [$         a    [        U5      n
 Nrf = f)zNCheck that this request is allowed to execute this fixturedef without
a param.N
nofuncargsFzG does not support fixtures, maybe unittest.TestCase subclass?
Node id: z
Function type: pytracerE   r   z=The requested fixture has no parameter defined for test:
    z

Requested fixture 'z' defined in:
z

Requested here:
rd   )r   rU  r"  r   r\   typer   r<   inspectr\  getframeinfor?   filenamelinenor}   relative_tor  rootpath
ValueErrorr%   funcr~   )r   r^   funcitem
has_paramsfixtures_not_supportedr=  frame	frameinfosource_pathsource_linenosource_path_strlocations               rS   rV  .FixtureRequest._check_fixturedef_without_param  sg    ##&&d2
!(<!G0==/ "$OO, -""&x."9"9!:< 
 e$MMOA&E,,U1X6I&y'9'9:K%,,M3"%k&=&=hoo>V>V&W"X #:??HOO4L4LMH' (&&0&8&8%9* $"#1]O5  e$%   3"%k"23s   .E E,+E,c                    U R                  5        Vs/ s H  oR                  PM     nnUR                  5         U$ s  snf rP   )rM  _fixturedefreverse)r   rP  valuess      rS   _get_fixturestack FixtureRequest._get_fixturestack  s:    595E5E5GH5G'%%5GH Is   <)r   r   r   r   N)r   rI   r   
str | Noner   z'Mapping[str, Sequence[FixtureDef[Any]]]r   zdict[str, FixtureDef[Any]]r   boolr   r   )r   rQ   r   rB   r   rC   r  FixtureDef[object]r	  rB   r   r   )r   r   )r   r,   )r   r   )r   zMutableMapping[str, Any])r   r9   r2  zCallable[[], object]r   r   )r7  zstr | MarkDecoratorr   r   )r=  r~  r   r   )r~   r}   r   r   )r~   r}   r   r   )r   zIterator[SubRequest])r~   r}   r   r  )r^   r  r   r   )r   zlist[FixtureDef[Any]])!r   r   r   r   r   r   propertyrR   abcabstractmethodr   rq   r
  r  r[   r  r  r   r!  r%  r   r,  rN   r3  r8  r>  rB  rG  rM  rE  rV  r|  r   r   rU   rS   r   r     s        A	
 1  
< 8 8 $  $ ! ! 	$0$ $ 
	$ $   $  $ ' ' $ $   ; ;   % %  
 ( ( 	$ $
	%25+B.Rh%BrU   r   c                     ^  \ rS rSrSrSS.SU 4S jjjr\SS j5       r      SS jr\S 5       r	SS	 jr
SS
 jrSS jrSrU =r$ )
TopRequesti  z7The type of the ``request`` fixture in a test function.Fr   c               P   > [         TU ]  S UUR                  R                  0 US9  g )N)r   r   r   r   r   )superr   _fixtureinfor   )r   r   r   	__class__s      rS   r   TopRequest.__init__  s0    !&33DD 	 	
rU   c                "    [         R                  $ rP   )rB   rI   r   s    rS   r   TopRequest._scope  s    ~~rU   c                    g rP   r   r  s      rS   r
  TopRequest._check_scope  s     	rU   c                    U R                   $ rP   )r   r   s    rS   r[   TopRequest.node  s    rU   c                $    SU R                   < S3$ )Nz<FixtureRequest for >)r[   r   s    rS   __repr__TopRequest.__repr__  s    %dii]!44rU   c                    U R                   nUR                   H2  nX!R                  ;  d  M  U R                  U5      UR                  U'   M4     g rP   )r   r  funcargsrG  )r   r   r~   s      rS   _fillfixturesTopRequest._fillfixtures!  s@    ((Gmm+)-)=)=g)Fg& )rU   c                :    U R                   R                  U5        g rP   )r[   r3  r1  s     rS   r3  TopRequest.addfinalizer'  s    		y)rU   r   )r   rI   r   r  r   r   r  r  r   r}   r   r  )r   r   r   r   r   r   r  r   r
  r[   r  r  r3  r   __classcell__r  s   @rS   r  r    sq    ABG 
 
  0  
	    5G* *rU   r  c                     ^  \ rS rSrSrSS.             SU 4S jjjrSS jr\SS j5       r\S 5       r	      SS	 jr
SS
 jrSS jrSrU =r$ )rJ  i+  zfThe type of the ``request`` fixture in a fixture function requested
(transitively) by a test function.Fr   c               (  > [         TU ]  UR                  UR                  UR                  UR
                  US9  Xl        XPl        U[        La  X0l	        X@l
        X l        U[        R                  L a  U R                  nOJU[        R                  L a!  [        U R                  U R                  5      nO[!        U R                  U5      nUc  U[        R"                  L a  U R                  nU(       d   SU SU R                  < 35       eXpl        g )N)r   r   r   r   r   z#Could not obtain a node for scope "z" for function )r  r   r   r~   r   r   rK  ry  r&   r^  r   _scope_fieldrB   rI   rW   r`   rs   rm   _node)	r   rP  rq   r^  r   r^   r   r[   r  s	           rS   r   SubRequest.__init__0  s     	**"** ..#44 	 	
 7>6@J"-#(ENN"&*&6&6Demm#$T%5%5t7G7GHD!$"2"2E:D<EU[[0##D 	
1%HXHXG[\	
t !
rU   c                @    SU R                   < SU R                  < S3$ )Nz<SubRequest z for r  )r   r   r   s    rS   r  SubRequest.__repr__V  s%    d..1t7G7G6J!LLrU   c                    U R                   $ rP   )r  r   s    rS   r   SubRequest._scopeY  s       rU   c                    U R                   $ rP   )r  r   s    rS   r[   SubRequest.node]  s    zzrU   c                "  ^  T R                   U:  a~  UR                  nSR                  U 4S jT R                  5        5       5      nT R	                  U5      n[        SUR                   SU ST R                   R                   SU SU 3
SS	9  g g )
N
c              3  F   >#    U  H  nTR                  U5      v   M     g 7frP   )_format_fixturedef_line)r   r^   r   s     rS   r   *SubRequest._check_scope.<locals>.<genexpr>i  s&      &":J ,,Z88":s   !z'ScopeMismatch: You tried to access the z scoped fixture z with a z2 scoped request object. Requesting fixture stack:
z
Requested fixture:
Frc  )r   r~   joinr|  r  r<   r  )r   r  r	  r~   fixture_stackrequested_fixtures   `     rS   r
  SubRequest._check_scopea  s    
 ;;(*22G II &"&"8"8":& M !% < <=Q R9/:O:O9P Q")8DKK,=,=+> ?..;_ =''8&9;  )rU   c                    UR                   n[        U5      u  p4[        U[        5      (       a*  [	        U R
                  R                  R                  U5      n[        U5      nU SUS-    SUR                   U 3$ )Nrd   r   z:  def )
rm  r   rZ   r   r@   r   rN   r   r*   r   )r   r^   factoryr   ri  sigs         rS   r  "SubRequest._format_fixturedef_linev  sr    //"7+dD!!t//77<<dCD q!GG,<,<+=cUCCrU   c                :    U R                   R                  U5        g rP   )ry  r3  r1  s     rS   r3  SubRequest.addfinalizer~  s    %%i0rU   )ry  r  rK  r  r^  r   )rP  r   rq   rB   r^  r   r   r   r^   r  r   r  r   r   r  r  r  )r^   r  r   r}   r  )r   r   r   r   r   r   r  r  r   r[   r
  r  r3  r   r  r  s   @rS   rJ  rJ  +  s    *  $!$! $! 	$!
 $! '$! $! 
$! $!LM ! !  0  
	*D1 1rU   rJ  c                  @    \ rS rSrSr S       SS jjrS	S jrSrg)
r<  i  z:Could not return a requested fixture (missing or invalid).Nc                R    Xl         X l        UR                  5       U l        X0l        g rP   )r~   rP  r|  fixturestackr=  )r   r~   rP  r=  s       rS   r   FixtureLookupError.__init__  s$     #557rU   c                   / nUR                   nU R                  R                  R                  /nUR	                  [        S U R                  5      5        U R                  nUb  [        U5      S:  a  US S nU H  n[        U5      u  pg [        R                  " [        U5      5      u  pU" SU SUS-    35        [        U5       HG  u  pUR                  5       nU" SU-   5        UR                  5       R!                  S5      (       d  MF    M     M     UGc   U R                  R(                  n[+        5       nU R                  R                  R,                  nUc   eUR.                  R1                  5        H;  u  nn[3        UR5                  UU5      5      nU(       d  M*  UR7                  U5        M=     U R8                  U;   a  S	U R8                   S
3nOSU R8                   S3nUSR;                  SR=                  [?        U5      5      5      -  nUS-  n[A        WWXU R8                  5      $ ! ["        [$        [&        4 a    SnU" XUS-   4-  5         GM  f = f)Nc                    U R                   $ rP   )rm  )xs    rS   <lambda>/FixtureLookupError.formatrepr.<locals>.<lambda>  s    166rU   r   r   zfile z, line z  defz+file %s, line %s: source code not availablez) recursive dependency involving fixture 'z
' detectedz	fixture 'z' not foundz
 available fixtures: {}z, z6
 use 'pytest --fixtures [testpath]' for help on them.)!appendrP  r   rw   r  mapr  r=  rf   r   rf  getsourcelinesr"   	enumeraterstriplstripre   OSError
IndexError	TypeErrorrR   r   r_   r   r   r   _matchfactoriesr   r~   r[  r  sortedFixtureLookupErrorRepr)r   tblinesaddliner\  r=  r  fspathri  linesr   r   line	error_msgfm	availabler_   r   r   faclists                      rS   
formatreprFixtureLookupError.formatrepr  s*   ..))--.S)4+<+<=>hh?s5zA~ #2JEH(2NF"11-2IJ
 %xwvzl;<(/GA;;=DD4K({{}//66	  0  ;--BI\\--44F%%%%'%8%8%>%>%@!kr11+vFG7MM$' &A ||y(?~ZX  "$,,{;.55diiy@Q6RSSCLLC%ffgDLLQQ; Z3 :I		VaZ$8899:s   !H44&II)r~   r  r=  rP  rP   )r~   r~  rP  r   r=  r~  r   r   )r   r  )r   r   r   r   r   r   r  r   r   rU   rS   r<  r<    s7    D OS!,:AK	+RrU   r<  c                  @    \ rS rSr            SS jrSS jrSrg)r  i  c                @    X0l         X@l        Xl        X l        XPl        g rP   )r  errorstringrh  firstlinenor~   )r   rh  r  r  r  r~   s         rS   r   FixtureLookupErrorRepr.__init__  s     & &rU   c                0   U R                    H"  nUR                  UR                  5       5        M$     U R                  R	                  S5      nU(       aq  UR                  [
        R                   SUS   R                  5        3SS9  USS   H4  nUR                  [
        R                   SUR                  5        3SS9  M6     UR                  5         UR                  [        R                  " U R                  5       SU R                  S-    35        g )Nr  z       r   Tredr   rd   )r  r  r  r  splitr   fail_markerstripflow_markerosr  rh  r  )r   twtbliner  r  s        rS   
toterminal!FixtureLookupErrorRepr.toterminal  s    llFGGFMMO$ #  &&t,GG)556geAhnn>N=OP   ab	-99:'$**,P   "
 		
299T]]+,Ad.>.>.B-CDErU   )r~   r  rh  r  r  N)rh  zstr | os.PathLike[str]r  r   r  Sequence[str]r  r}   r~   r~  r   r   )r  r   r   r   )r   r   r   r   r   r  r   r   rU   rS   r  r    sG    (  	
   
FrU   r  c                   [         R                  " U 5      (       ab  [        [        S[        [
           4   U 5      n U " S0 UD6n [        U5      n[        R                  " [        X5      nUR                  U5        U$ [        [        S[
        4   U 5      n U " S0 UD6nU$ ! [         a    [        UR                   S35      S ef = f)N.z did not yield a valuer   )rf  isgeneratorfunctionr   r   r   rL   nextStopIterationrl  r   	functoolspartial_teardown_yield_fixturer3  )fixturefuncrP  kwargs	generatorfixture_resultr2  s         rS   call_fixture_funcr    s     "";//8C<)@$@A;O)&)		W!)_N %%&={V	Y'  8C$56D$.v.  	W 3 344JKLRVV	Ws   B! !$Cc           	          [        U5        [        U 5      u  p#[        S[        U 5      R	                  5        SU SUS-    3SS9  g! [
         a     gf = f)zExecute the teardown of a fixture function by advancing the iterator
after the yield and ensure the iteration ends (if not it means there is
more than one yield in the function).z-fixture function has more than one 'yield':

r  rd   r   Frc  N)r  r   r<   r   indentr  )r  itfsri  s       rS   r  r    sj    
R !-
=k"))+,Bd!FQJ<! 		
	  s   A 
AAc                     U " XS9n[        U[        5      (       d  [	        SU  SU SU< 3SS	9  U$ ! [          a  n[        SU  SU S35      UeS nAff = f)
N)fixture_namer  zError evaluating z while defining fixture 'zC'.
Expected a function with the signature (*, fixture_name, config)z	Expected z+ to return a 'str' while defining fixture 'z', but it returned:
Frc  )	Exceptionr  rZ   r}   r<   )scope_callabler   r  r  es        rS   _eval_scope_callabler    s    
  \I fc""''RS_R``uj	

 M  //H WO O
 	s   3 
AAAc                      \ rS rSrSr S\SSS.                     SS jjjr\SS j5       r\SS j5       r	SS	 jr
SS
 jrSS jrSS jrSS jrSrg)
FixtureDefi  zA container for a fixture definition.

Note: At this time, only explicitly documented fields and methods are
considered public stable API.
NF)r[   _autouser   c               x   [        U
5        U[        L a  [        R                  " [        SS9  U[        L a  S nU[        La  UOS U l        U[        La  UR                  O
U=(       d    SU l        U[        L=(       d    US LU l        X@l	        X0l
        Uc  [        R                  nO[        U5      (       a  [        XSU5      n[        U[         5      (       a.  [        R"                  " USUR$                   S3U R                  S9nXPl        X`l        Xpl        [-        XCS9U l        S U l        / U l        Xl        g )N   rQ  rb   z	Fixture '')descrwherer   )r1   r&   rY  rZ  r3   r[   r\   r]   _has_locationrm  r~   rB   rI   callabler  rZ   r}   	from_userr   r   rU  idsr#   r   rF  _finalizersr  )r   r  r]   r~   rm  rq   rU  r  r[   r  r   s              rS   r   FixtureDef.__init__   s    	y!6>MM3BVF $(v#544	" -1,>T[[V\r %)$6$L&:L	%=NNEe__(@EeS!!OOyq9E ## .tB IM>@ !rU   c                .    U R                   R                  $ r  r  r   s    rS   rq   FixtureDef.scopel  r  rU   c                L    [         R                  " [        SS9  U R                  $ )Nr	  rQ  )rY  rZ  r6   r  r   s    rS   has_locationFixtureDef.has_locationq  s    8QG!!!rU   c                :    U R                   R                  U5        g rP   )r  r  r1  s     rS   r3  FixtureDef.addfinalizerv  s    	*rU   c                   U R                   c  g / nU R                  (       a5  U R                  R                  5       n U" 5         U R                  (       a  M5  UR
                  nS U l         U R                  R                  5         [        U5      S:X  a  US   e[        U5      S:  a#  SU R                   SU 3n[        XbS S S2   5      eg ! [         a  nUR	                  U5         S nANS nAff = f)Nr   r   z#errors while tearing down fixture "z" of r   )
rF  r  popBaseExceptionr  r[   r   rf   r~   rG   )r   rP  
exceptionsfinr  r[   r=  s          rS   finishFixtureDef.finishy  s    % *,
""&&(C%  || " z?aQ-_q 7~U4&QC$STrT*:;; ! ! %!!!$$%s   C 
C0C++C0c                z  ^ ^ / nT R                    H%  nTR                  U5      nUR                  U5        M'     T R                  b  T R	                  T5      nT R                  S   n [        XV:H  5      nU(       aA  T R                  S   b"  T R                  S   u  pUR                  U	5      eT R                  S   $ T R                  T5        T R                  b   e[        R                  " T R                  TS9n
U H  nUR                  U
5        M     T R                  (       a   eT R                  UU 4S j5        TR                  R                  n UR!                  T TS9nTR                  R                  U
5        U$ ! [        [        4 a    XVL n GN$f = f! TR                  R                  U
5        f = f)z=Return the value of this fixture, executing it if not cached.r   r	  r   rS  c                 L   > T R                   R                  R                  TT S9$ )Nr^   rP  )r[   ihookpytest_fixture_post_finalizer)rP  r   s   rS   r  $FixtureDef.execute.<locals>.<lambda>  s%    GLL&&DD E rU   r$  )r   rE  r  rF  	cache_keyr  rl  RuntimeErrorwith_tracebackr   r  r  r3  r  r[   r%  pytest_fixture_setup)r   rP  *requested_fixtures_that_should_finalize_usr~   r^   request_cache_keyr(  	cache_hitexcexc_tbr2  parent_fixturer%  r  s   ``            rS   r]  FixtureDef.execute  s    682}}G 77@J 7==jI % ) $w 7**1-I; !!2!?@	
 %%a(4"&"4"4Q"7KC,,V44--a00 KK %%---
 %%dkk7C	HN''	2 I
 ####	
 ""	1 $)#=#= $> $F
 LL%%i0U - ;-:	;P LL%%i0s   (F F FFF:c                    [        USS 5      $ )Nr^  )r"  )r   rP  s     rS   r(  FixtureDef.cache_key  s    w..rU   c                \    SU R                   < SU R                  < SU R                  < S3$ )Nz<FixtureDef argname=z scope=z baseid=r  )r~   rq   r]   r   s    rS   r  FixtureDef.__repr__  s/    %dll%5WTZZN(SWS^S^RaabccrU   )r  r  r  r   r~   r   r]   rF  rm  r  r[   rU  rP   )r  r,   r]   str | None | NotSetTyper~   r}   rm  _FixtureFunc[FixtureValue]rq   z=Scope | ScopeName | Callable[[str, Config], ScopeName] | NonerU  Sequence[object] | Noner  Atuple[object | None, ...] | Callable[[Any], object | None] | Noner[   nodes.Node | NotSetTyper  r  r   r  r   r   r  )r   r  r  )rP  rJ  r   r   )rP  rJ  r   rL   )rP  rJ  r   objectr  )r   r   r   r   r   r&   r   r  rq   r  r3  r   r]  r(  r  r   r   rU   rS   r  r    s     RVJ! )/J!J! (J! 	J!
 )J! MJ! (J! OJ! &J! J! J! 
J!X ! ! " "+<2DL/drU   r  c                  :   ^  \ rS rSrSrSU 4S jjrSS jrSrU =r$ )rT  i  zzA custom FixtureDef for the special "request" fixture.

A new one is generated on-demand whenever "request" is requested.
c                   >^ [         TU ]  TR                  [        SU4S j[        R
                  S TR                  SS9  TS/S 4U l        g )NrP  c                    > T $ rP   r   rS  s   rS   r  ,RequestFixtureDef.__init__.<locals>.<lambda>  s    rU   T)r  r]   r~   rm  rq   rU  r[   r   r   )r  r   r  r&   rB   rI   r[   rF  )r   rP  r  s    `rS   r   RequestFixtureDef.__init__  sL    >> .. 	 		
 &sD1rU   c                    g rP   r   r1  s     rS   r3  RequestFixtureDef.addfinalizer  s    rU   )rF  )rP  r   r   r   r  )	r   r   r   r   r   r   r3  r   r  r  s   @rS   rT  rT    s    
2 rU   rT  c                   U R                   nUR                  nU R                  [        R                  L aK  [        US5      (       a:  UR                  n[        U[        5      (       d  [        R                  " [        SS9  Ubm  [        US5      (       a'  [        UUR                  R                  5      (       d  U$ [        U R                   5      nX R                   :w  a  UR                  U5      nU$ )zGGet the actual callable that can be called to obtain the fixture
value.__self__r	  rQ  )rm  r!  r   rB   rm   r   rE  rZ   re  rY  rZ  r2   r  r$   __get__)r^   rP  r  r!  bound_tos        rS   resolve_fixture_functionrH    s    
 //K HEKK';
++"++H h--;J ;
++J  **5
 5
 
0//)%--h7KrU   c                P   0 nU R                    H  nUR                  U5      X#'   M     [        X5      nU R                  U5      n[        R
                  " U5      (       d  [        R                  " U5      (       aG  U R                  (       a  SOSn[        UR                  R                  < SUR                  < U S3SS9   [        XAU5      nXuS4U l        U$ ! [         aA  n[        U[        R                   5      (       a  SUl        SXXUR$                  44U l        e SnAff = f)	zExecution of fixture setup.z with autouse=Truerb   z requested an async fixture z, with no plugin or hook that handled it. This is an error, as pytest does not natively support it.
See: https://docs.pytest.org/en/stable/deprecations.html#sync-test-depending-on-async-fixtureFrc  TN)r   rG  rH  r(  rf  isasyncgenfunctioniscoroutinefunctionr  r<   r[   r   r   r  r>   rZ   r=   r  _use_item_location__traceback__rF  )	r^   rP  r  r~   r  my_cache_keyauto_strr  r  s	            rS   r+  r+    s(    F&&!11': ' +:?K''0L!!+..'2M2M3 3 ,6+>+>'B||  ##?@S@S?VW_V` al l 		
	";@ !'d;JM  a(( $(A $(,AOO8L#M
 s   C 
D%$<D  D%c                  v    \ rS rSr% S\S'   S\S'   SrS\S'   S	rS
\S'   S	rS\S'   SrS\S'   SS jr	SS jr
Srg	)FixtureFunctionMarkeri<  .ScopeName | Callable[[str, Config], ScopeName]rq   ztuple[object, ...] | NonerU  Fr  autouseNr:  r  r~  r   zdataclasses.InitVar[bool]r   c                    [        U5        g rP   r0   )r   r   s     rS   __post_init__#FixtureFunctionMarker.__post_init__G  s
    y!rU   c                t   [         R                  " U5      (       a  [        S5      e[        U[        5      (       a  [        SUR
                  < 35      e[        US5      (       a  [        S5        [	        XSS9nU R                  =(       d    UR
                  nUS:X  a  [        U5      n[        SU 3S	S
9  U$ )Nz2class fixtures not supported (maybe in the future)zE@pytest.fixture is being applied more than once to the same function 
pytestmarkzMarks cannot be applied to fixtures.
See docs: https://docs.pytest.org/en/stable/deprecations.html#applying-a-mark-to-a-fixture-functionT)r  fixture_function_markerr   rP  z?'request' is a reserved word for fixtures, use another name:
  Frc  )
rf  isclassrl  rZ   ru   r   r   r<   r   r%   )r   r  fixture_definitionr   rv  s        rS   __call__FixtureFunctionMarker.__call__J  s    ??8$$QRRh 9::WX`XiXiWlm  8\**v
 7t
 yy-H--9"8,HRS[R\]
 "!rU   r   )r   r  r   r   )r  FixtureFunctionr   ru   )r   r   r   r   r   rS  r  r   r   rU  r\  r   r   rU   rS   rQ  rQ  <  sD     :9%%GTMQC	JQD*+0I(0""rU   rQ  c                  b    \ rS rSrSSS.         SS jjrSS jrSS jrSS jrSS	 jrS
r	g)ru   ii  NF)r!  r   c               *   [        U5        UR                  =(       d    UR                  U l        U R                  U l        X l        Ub.  [	        [
        S[        4   UR                  U5      5      U l        OXl        [        R                  " X5        g )N.)r1   r   r   rv   r   r   r   rF  _fixture_functionr  update_wrapper)r   r  rY  r!  r   s        rS   r   "FixtureFunctionDefinition.__init__j  sy     	y!+00EH4E4E	 		(?%%)c"H$4$4X$>&D" &."  0rU   c                "    SU R                    S3$ )Nz<pytest_fixture(z)>ra  r   s    rS   r  "FixtureFunctionDefinition.__repr__  s    !$"8"8!9<<rU   c                B    [        U R                  U R                  USS9$ )zDBehave like a method if the function it was applied to was a method.T)r  rY  r!  r   )ru   ra  rv   )r   r!  owners      rS   rF  !FixtureFunctionDefinition.__get__  s'    (++$($A$A	
 	
rU   c                8    SU R                    S3n[        USS9  g )Nz	Fixture "aE  " called directly. Fixtures are not meant to be called directly,
but are created automatically when test functions request them as parameters.
See https://docs.pytest.org/en/stable/explanation/fixtures.html for more information about fixtures, and
https://docs.pytest.org/en/stable/deprecations.html#calling-fixtures-directlyFrc  )r   r<   )r   argskwdsmessages       rS   r\  "FixtureFunctionDefinition.__call__  s*    		{ #\ \ 	 	We$rU   c                    U R                   $ rP   re  r   s    rS   _get_wrapped_function/FixtureFunctionDefinition._get_wrapped_function  s    %%%rU   )r   ra  rv   r   )
r  Callable[..., Any]rY  rQ  r!  zobject | Noner   r  r   r   r  rP   )rk  r   rl  r   r   r   )r   rr  )
r   r   r   r   r   r  rF  r\  rp  r   r   rU   rS   ru   ru   i  sU     #'1 %1 "7	1
  1 1 
1,=
%&rU   ru   rq   rU  rS  r  r   c                   g rP   r   fixture_functionrq   rU  rS  r  r   s         rS   fixturerw    s     !$rU   c                   g rP   r   ru  s         rS   rw  rw    s      rU   r  Fc          	         [        UUb  [        U5      OSUUc  SO[        U5      (       a  UO
[        U5      USS9nU (       a  U" U 5      $ U$ )aE  Decorator to mark a fixture factory function.

This decorator can be used, with or without parameters, to define a
fixture function.

The name of the fixture function can later be referenced to cause its
invocation ahead of running tests: test modules or classes can use the
``pytest.mark.usefixtures(fixturename)`` marker.

Test functions can directly use fixture names as input arguments in which
case the fixture instance returned from the fixture function will be
injected.

Fixtures can provide their values to test functions using ``return`` or
``yield`` statements. When using ``yield`` the code block after the
``yield`` statement is executed as teardown code regardless of the test
outcome, and must yield exactly once.

:param scope:
    The scope for which this fixture is shared; one of ``"function"``
    (default), ``"class"``, ``"module"``, ``"package"`` or ``"session"``.

    This parameter may also be a callable which receives ``(fixture_name, config)``
    as parameters, and must return a ``str`` with one of the values mentioned above.

    See :ref:`dynamic scope` in the docs for more information.

:param params:
    An optional list of parameters which will cause multiple invocations
    of the fixture function and all of the tests using it. The current
    parameter is available in ``request.param``.

:param autouse:
    If True, the fixture func is activated for all tests that can see it.
    If False (the default), an explicit reference is needed to activate
    the fixture.

:param ids:
    Sequence of ids each corresponding to the params so that they are
    part of the test id. If no ids are provided they will be generated
    automatically from the params.

:param name:
    The name of the fixture. This defaults to the name of the decorated
    function. If a fixture is used in the same module in which it is
    defined, the function name of the fixture will be shadowed by the
    function arg that requests the fixture; one way to resolve this is to
    name the decorated function ``fixture_<fixturename>`` and then use
    ``@pytest.fixture(name='<fixturename>')``.
NT)rq   rU  rS  r  r   r   )rQ  tupler  )rv  rq   rU  rS  r  r   fixture_markers          rS   rw  rw    sW    v + & 2uV}KDHSMMSuSzN .//rU   zT@pytest.yield_fixture is deprecated. Use @pytest.fixture instead; they are the same.)categoryc          	     Z    [         R                  " [        SS9  [        U /UQ7UUUUUS.6$ )z(Return a) decorator to mark a yield-fixture factory function.

.. deprecated:: 3.0
    Use :py:func:`pytest.fixture` directly instead.
r	  rQ  rs  )rY  rZ  r8   rw  )rv  rq   rU  rS  r  r   rk  s          rS   yield_fixturer~    s@    $ MM-A.	  rU   )rq   c                    U R                   $ )zSession-scoped fixture that returns the session's :class:`pytest.Config`
object.

Example::

    def test_foo(pytestconfig):
        if pytestconfig.get_verbosity() > 0:
            ...

r  rS  s    rS   pytestconfigr    s     >>rU   c           	         U R                  SS/ SS9  U R                  S5      nUR                  SSSS	S
SS9  UR                  SSSS
SS9  g )Nusefixturesrk  z5List of default fixtures to be used with this project)re  defaulthelpgeneralz
--fixturesz
--funcargs
store_trueshowfixturesFziShow available fixtures, sorted by plugin appearance (fixtures with leading '_' are only shown with '-v'))actiondestr  r  z--fixtures-per-testshow_fixtures_per_testzShow fixtures per test)addinigetgroup	addoption)parsergroups     rS   pytest_addoptionr  )  sv    
MMD	   OOI&E	OO?   
OO%%  rU   c                    U R                   R                  (       a  [        U 5        gU R                   R                  (       a  [        U 5        gg )Nr   )optionr  r  r  s    rS   pytest_cmdline_mainr  C  s5    }}!!V}}++v&rU   c                V   [        U[        5      (       a   [        R                  X(       a  SOS5      nU$ [        U[        5      (       a;  [        R                  U S5      nU H  nX@;  a  [        SU SU S3SS9  SX4'   M     U$ [        SU S[        U5      R                   3SS9  W$ )	a
  Resolve if each parametrized argument must be considered an indirect
parameter to a fixture of the same name, or a direct parameter to the
parametrized function, based on the ``indirect`` parameter of the
parametrize() call.

:param argnames:
    List of argument names passed to ``parametrize()``.
:param indirect:
    Same as the ``indirect`` parameter of ``parametrize()``.
:param nodeid:
    Node ID to which the parametrization is applied.
:returns:
    A dict mapping each arg name to either "indirect" or "direct".
indirectdirectzIn z: indirect fixture 'z' doesn't existFrc  z1: expected Sequence or boolean for indirect, got )rZ   r  r   r   r   r<   re  r   )r   r  r\   arg_directnessargs        rS   _resolve_args_directnessr  M  s    ( (D!!xxXV  
Hh	'	'x:C"&!5cU/J! #-N  	 	&J4PX>KbKbJcd	
 rU   c                N   [        5       nU R                  SS9 H  nUR                  R                  SS5      n[        R
                  " UR                  0 UR                  D6u  pE[        XCU R                  5      nUR                  S UR                  5        5       5        M     U$ )zReturn all direct parametrization arguments of a node, so we don't
mistake them for fixtures.

Check https://github.com/pytest-dev/pytest/issues/5036.

These things are done later as well when dealing with parametrization
so this could be improved.
parametrizer  r  Fc              3  :   #    U  H  u  pUS :X  d  M  Uv   M     g7f)r  Nr   )r   r~   
directnesss      rS   r   /_get_direct_parametrize_args.<locals>.<genexpr>  s$      $
';#X% G';s   	)r   iter_markersr  r   r:   _parse_parametrize_argsrk  r  r\   r   r   )r[   parametrize_argnamesr7  r  
p_argnamesr   p_directnesss          rS   _get_direct_parametrize_argsr  t  s     &)U###7==$$Z7$<<[[
"MM

 0
dkkR## $
'3'9'9';$
 	
 8  rU   c                 L    [        [        R                  S U  5       5      5      $ )zDDe-duplicate the sequence of names while keeping the original order.c              3  6   #    U  H  o  H  o"v   M     M     g 7frP   r   )r   seqr   s      rS   r   $deduplicate_names.<locals>.<genexpr>  s     Dtttts   )rz  r   r   )seqss    rS   deduplicate_namesr    s     DtDDEErU   c                     \ rS rSrSrSS jr        SS jrS S jr\" SS9    S!S j5       r	SS	 jr
S"S
 jrS#S jrS$S jr        S%S jrS&S jrS'S jr\SSSS\S.                 S(S jjr\    S)S j5       r\\" S5            S*S j5       5       r\  S+         S,S jj5       r\\4\\S.         S-S jjjr      S.S jr      S/S jrSrg)0rQ   i  a  pytest fixture definitions and information is stored and managed
from this class.

During collection fm.parsefactories() is called multiple times to parse
fixture function definitions into FixtureDef objects and internal
data structures.

During collection of test functions, metafunc-mechanics instantiate
a FuncFixtureInfo object which is cached per node/func-name.
This FuncFixtureInfo object is later retrieved by Function nodes
which themselves offer a fixturenames attribute.

The FuncFixtureInfo object holds information about fixtures and FixtureDefs
relevant for a particular function. An initial list of fixtures is
assembled like this:

- config-defined usefixtures
- autouse-marked fixtures along the collection chain up from the function
- usefixtures markers at module/class/function level
- test function funcargs

Subsequently the funcfixtureinfo.fixturenames attribute is computed
as the closure of the fixtures needed to setup the initial fixtures,
i.e. fixtures needed by fixture functions themselves are appended
to the fixturenames list.

Upon the test-setup phases all fixturenames are instantiated, retrieved
by a lookup of their FuncFixtureInfo.
c                    Xl         UR                  U l        0 U l        U[        U R                  R	                  S5      5      0U l        0 U l        0 U l        UR                  R                  R                  U S5        U R                  U5        g )Nr  
funcmanage)rN   r  r   r   getini_node_autousenames_nodeid_autousenames_pending_conftestspluginmanagerregister#_flush_pending_conftests_to_session)r   rN   s     rS   r   FixtureManager.__init__  s    %nn
 JL T$++,,];<G

 BD! >@$$--dLA
 	009rU   c                
   Ub'  [        USS5      (       d  [        X!R                  US9nOSnU R                  U5      nU R	                  U5      n[        XeU5      n[        U5      nU R                  UUUS9u  p[        XGX5      $ )aC  Calculate the :class:`FuncFixtureInfo` for an item.

If ``func`` is None, or if the item sets an attribute
``nofuncargs = True``, then ``func`` is not examined at all.

:param node:
    The item requesting the fixtures.
:param func:
    The item's function.
:param cls:
    If the function is a method, the method's class.
rb  F)r   r   r   )
parentnoder   ignore_args)	r"  r#   r   _getusefixturesnames_getautousenamesr  r  getfixtureclosurer   )r   r[   rm  r   r   usefixturesnamesautousenamesr   direct_parametrize_argsr   r   s              rS   getfixtureinfoFixtureManager.getfixtureinfo  s    $ GD,$F$F&t))EHH44T:,,T2(R">t"D)-)?)?%/ *@ *
& x}VVrU   c                    U(       a<  UR                  S5      (       a&  [        U5      nUR                  nXR                  U'   g U R	                  XR
                  S9  g )Nzconftest.pyholderr[   )endswithr?   r_   r  parsefactoriesrN   )r   pluginplugin_nameconftestpathconftest_dirs        rS   pytest_plugin_registered'FixtureManager.pytest_plugin_registered  sS    
 ;//>>
 (4L'..L4:##L1 vLLArU   T)wrapperc              #     #    S v n[        U[        R                  5      (       a8  U R                  R	                  UR
                  S 5      nUb  U R                  X1S9  U$ 7f)Nr  )rZ   r   	Directoryr  r  r   r  )r   	collectorr  r  s       rS   pytest_make_collect_report)FixtureManager.pytest_make_collect_report  sU      i11,,00FF!##6#Bs   AA c                D   UR                   R                  n/ n[        U R                  R	                  5       5       H  u  pE UR                  U5        M     U H!  u  pEU R                  U	 U R                  XQS9  M#     g! [         a    UR                  XE45         Mb  f = f)zAssign Session scope to initial conftests whose directories won't
be collected as Directory nodes (e.g. ancestors above rootdir).r  N)	r  rk  r   r  r   rj  rl  r  r  )r   rN   rk  orphanedr  r  s         rS   r  2FixtureManager._flush_pending_conftests_to_session  s     >>**.0$()@)@)F)F)H$I L8((2	 %J %- L''5v< %-  8 678s   A??BBc                8    U R                   R                  5         g)aN  Clean up any conftests that were never collected by a Directory.

After __init__ flushes above-rootdir conftests and collection pops
under-rootdir ones, remaining entries mean collection was interrupted
(e.g. UsageError for a bad path). These conftests' fixtures aren't
needed since their directories' tests weren't collected either.
N)r  r   r   s    rS   pytest_collection_finish'FixtureManager.pytest_collection_finish  s     	%%'rU   c              #  
  #    UR                  5        Hg  nU R                  R                  U5      nU(       a
  U Sh  vN   U R                  R                  UR                  5      nU(       d  M]  U Sh  vN   Mi     g NA N7f)z8Return the names of autouse fixtures applicable to node.N)	listchainr  r   r  r\   )r   r[   r  	basenamesnodeid_basenamess        rS   r  FixtureManager._getautousenames&  sn     ..*J//33J?I$$$#88<<Z=N=NO+++ + % ,s'   ;BA?.B0B5B6
BBc              #     #    UR                  SS9 HR  u  p#UR                  (       d(  UR                  [        SUR                   S35      5        UR                   Sh  vN   MT     g N	7f)z<Return the names of usefixtures fixtures applicable to node.r  r  zusefixtures() in z  without arguments has no effectN)iter_markers_with_noderk  rZ  rD   r\   )r   r[   marker_nodemarks       rS   r  #FixtureManager._getusefixturesnames1  sc     !%!<!<-!<!PK99  !+DKK=8XY
 yy   "Q !s   AA+A) 
A+c                b   ^ ^^^ 0 mSUUUU 4S jjnSU4S jjn[        [        UUS9USS9nUT4$ )Nc                   > U T;   a  g TR                  U 5      nU(       d  TR                  U T5      nU(       d  g UTU '   U$ rP   )r   r   )r~   r   r   r  r  r   s     rS   r   8FixtureManager.getfixtureclosure.<locals>.getfixturedefsK  sI    +%)--g6K"11':F"+6(rU   c                n   >  TU    nUS   R                   $ ! [         a    [        R                  s $ f = f)Nr   )r   KeyErrorrB   rI   )arg_namer   r   s     rS   sort_by_scope7FixtureManager.getfixtureclosure.<locals>.sort_by_scopeX  s?    .-h7 #2---  &~~%&s    44r   T)keyrz  )r~   r}   r    Sequence[FixtureDef[Any]] | None)r  r}   r   rB   )r  r   )r   r  r   r  r   r  fixturenames_closurer   s   `` `   @rS   r   FixtureManager.getfixtureclosure<  sK     AC	 		.  &$-  
 $_44rU   c           
     ,   UR                    H  nUR                  R                  US5      n[        U5       HV  nUR                  b4  UR                  UUR                  SUR                  UR                  S9    Mn  X$R                  ;  d  MU    M     M     g)zLGenerate new tests based on parametrized fixtures used by the given metafuncr   NT)r  rq   r  )	r  r   r   r   rU  r  rq   r  r   )r   metafuncr~   r   r^   s        rS   pytest_generate_tests$FixtureManager.pytest_generate_testsk  s    ,,G#4488"EL '|4
$$0(("))!%(..&NN )   "5"55% 5 -rU   c                     [        U5      US S & g rP   )r   )r   r   s     rS   pytest_collection_modifyitems,FixtureManager.pytest_collection_modifyitems  s     'arU   r  NF)r\   rq   rU  r  rS  r[   c                  U[         Ld	  U[         L a  [        R                  " [        SS9  [	        U R
                  UUUUUUSUUS9
n	U R                  R                  U/ 5      n
[        U
5       H(  u  p[        X5      (       d  M  U
R                  X5          O   U
R                  U	5        U(       a  U[         La,  U R                  R                  U/ 5      R                  U5        gU[         La/  Ub,  U R                  R                  U/ 5      R                  U5        gU R                  R                  U R                  / 5      R                  U5        gg)a  Register a fixture

:param name:
    The fixture's name.
:param func:
    The fixture's implementation function.
:param nodeid:
    The visibility of the fixture (deprecated, use node instead).
    The fixture will be available to the node with this nodeid and
    its children in the collection tree. None means global visibility.
:param node:
    The node where the fixture is defined (preferred over nodeid).
    When provided, enables node-based matching which is more robust.
:param scope:
    The fixture's scope.
:param params:
    The fixture's parametrization params.
:param ids:
    The fixture's IDs.
:param autouse:
    Whether this is an autouse fixture.
r	  rQ  T)
r  r]   r~   rm  rq   rU  r  r   r  r[   N)r&   rY  rZ  r5   r  r  r   
setdefaultr  ri   insertr  r  r  rN   )r   r   rm  r\   rq   rU  r  rS  r[   fixture_defr  r   existings                rS   _register_fixture FixtureManager._register_fixture  s)   F 46>MM3B ;;
 ''224< %W-KA*8AAq. .
 NN;'6!''224<CCDIv%&*<))44VR@GGM ''224<<DKKDQ rU   c                    [        5       erP   r   )r   node_or_objs     rS   r  FixtureManager.parsefactories  s    
 "##rU   z\parsefactories(obj, nodeid) is deprecated, use parsefactories(holder=obj, node=node) insteadc                    [        5       erP   r   )r   r  r\   s      rS   r  r         "##rU   c                   [        5       erP   r   )r   r  r\   r  r[   s        rS   r  r    r  rU   r  c               6   [         n[         nU[         La  UnUnOxU[         L a  [        S5      eU[         La  [        R                  " [        SS9  UnUnO=[        U[        R                  5      (       d   e[        [        UR                  5      nUn[        U5      (       d+  [        U[        R                  5      (       d  [        U5      nOUn[        U5       H  n	[!        XS5      n
[        U
5      ["        L d  M#  U
R$                  nUR&                  (       a  UR&                  nOU	n [)        Xy5      nUR-                  5       nU R/                  UUUR0                  UR2                  UR4                  UR6                  UUS9  M     g! [*         a    U
n Naf = f)a  Collect fixtures from a collection node or object.

Found fixtures are parsed into `FixtureDef`s and saved.

The preferred API uses keyword-only arguments:
- ``holder``: The object to scan for fixtures.
- ``node``: The node determining fixture visibility.

Legacy positional API (translated internally):
- ``parsefactories(node)``: Uses node.obj as holder, node for scope.
- ``parsefactories(obj, nodeid)``: Uses obj as holder, nodeid string for scope.
z/parsefactories() requires holder or node_or_objr	  rQ  N)r   rm  rq   rU  r  rS  r[   r\   )r&   r  rY  rZ  r7   rZ   r   Noder   r<  rw   r)   types
ModuleTypere  dirr(   ru   rv   r   r"  r   rp  r  rq   rU  r  rS  )r   r  r\   r  r[   effective_nodeeffective_nodeid	holderobjholderobj_tpr   obj_ubr7  r   rw   rm  s                  rS   r  r    sk   , 394:I!NF"MNN6!MM:qI#I% k5::6666V[__5I(N I&&z)UEUEU/V/V#'	?L$L	ND ",d;FF|8888;;#);;L#'L!!)2C
 002&&% ,,!==

"NN'+ ' 	) # & ! C!s   +F		FFc                v     U R                   U   n[        U R                  X25      5      $ ! [         a     gf = f)a  Get FixtureDefs for a fixture name which are applicable
to a given node.

Returns None if there are no fixtures at all defined with the given
name. (This is different from the case in which there are fixtures
with the given name, but none applicable to the node. In this case,
an empty result is returned).

:param argname: Name of the fixture to search for.
:param node: The requesting Node.
N)r   r  rz  r  )r   r~   r[   r   s       rS   r   FixtureManager.getfixturedefsI  sC    	//8K T))+<==  		s   + 
88c              #    #    [        UR                  5       5      nU Vs1 s H  oDR                  iM     nnU H>  nUR                  b  UR                  U;   a  Uv   M&  M(  UR                  U;   d  M:  Uv   M@     g s  snf 7frP   )r   rY   r\   r[   r]   )r   r   r[   parent_nodesnparentnodeidsr^   s          rS   r  FixtureManager._matchfactories]  st      4,,./+78<a<8%J*??l2$$ 3""m3   & 9s   BA<:B3B)r   r  r  r  r  rN   rN   r9   r   r   )r[   
nodes.Itemrm  zCallable[..., object] | Noner   r   r   r   )r  r+   r  r}   r   r   )r  znodes.Collectorr   z-Generator[None, CollectReport, CollectReport]r   )r[   
nodes.Noder   r   )r[   r  r   r   )r  r  r   r   r  zAbstractSet[str]r   z6tuple[list[str], dict[str, Sequence[FixtureDef[Any]]]])r  rJ   r   r   )r   list[nodes.Item]r   r   )r   r}   rm  _FixtureFunc[object]r\   r7  rq   z6Scope | ScopeName | Callable[[str, Config], ScopeName]rU  r9  r  r:  rS  r  r[   r;  r   r   )r  r  r   r   )r  r<  r\   r~  r   r   )..)
r  r'   r\   r'   r  r<  r[   r  r   r   )
r  z nodes.Node | object | NotSetTyper\   r7  r  zobject | NotSetTyper[   r;  r   r   )r~   r}   r[   r  r   r  )r   zIterable[FixtureDef[Any]]r[   r  r   zIterator[FixtureDef[Any]])r   r   r   r   r   r   r  r  r.   r  r  r  r  r  r  r  r  r&   r  r   r  r!   r   r  r   r   rU   rS   rQ   rQ     s   <:4"W"W +"W 	"W
 
"WHB$ d(	6 = (	,	!-5-5 &-5 &	-5
 
@-5^@( +1HR*.QU(.LR LR #	LR
 (LR FLR (LR OLR LR &LR 
LR\ $$ 
$ $ f$$ $ 
	$ $  #& $$ $
 $ $ 
$ $ 9?*0M
 '-(.M5M (M
 $M &M 
M^>>",>	)>(!4!<F!	"!rU   rQ   c                (    SSK Jn  U" U [        5      $ Nr   )wrap_session)_pytest.mainr  _show_fixtures_per_testr  r  s     rS   r  r  n  s    ) 788rU   c                    [        [        X5      5      n[        SS5      n [        X2R                  [        5      -  5      $ ! [
         a    [        X5      s $ f = f)Nz...rr   )r   r%   r}   rj  _PYTEST_DIRrl  r@   )invocation_dirrm  locprefixs       rS   _pretty_fixture_pathr$  w  sS    
{40
1C%#F06OOK8899 0>//0s   A AAc              #     #    SSK Jn  [        U SS5      nUc  g[        UR                  R                  5       5       H)  u  p4U(       d  M  US   n[        XQ5      (       a  M%  Uv   M+     g7f)a|  Returns all fixtures used by the test item except for those created by
direct parametrization and those requested dynamically with
``request.getfixturevalue``.

The justification for excluding fixtures created by direct parametrization
is that for users, they are internal implementation detail.

Dynamically requested fixtures are excluded because they are not known
statically.
r   )DirectParamFixtureDefr  Nr   )rX   r&  r"  r  r   r   rZ   )testr&  fixture_infor~   r   r^   s         rS   _get_fixtures_per_testr)    sj      5 ,34+NL !'|'D'D'J'J'L M _
j88 !Ns   A)A+c                &  ^^^^^	 SS K nUR                  5         U R                  R                  mUR                  R                  U 5      mU R                  5       mSU4S jjmSUUU4S jjm	SUUU	4S jjnUR                   H  nU" U5        M     g )Nr   c                F   > [        U T5      n[        T[        U5      5      $ rP   )r%   r@   r   )rm  r"  r!  s     rS   get_best_relpath1_show_fixtures_per_test.<locals>.get_best_relpath  s     $/>4955rU   c                  > U R                   nTS::  a  UR                  S5      (       a  g [        TU R                  5      nTR	                  U SS9  TR	                  SU 3SS9  TR	                  S5        [
        R                  " U R                  5      nU(       a&  [        TTS::  a  UR                  SS	S
9S   OU5        g TR                  SSS9  g )Nr   r   Tgreen -- yellowr  

r   maxsplit    no docstring availabler  )
r~   re   r$  rm  writerf  getdocwrite_docstringr  r  )r  r~   
prettypathfixture_docr!  r  verboses       rS   write_fixture._show_fixtures_per_test.<locals>.write_fixture  s    %%a<G..s33).+:J:JK

G9T*
4
|$T2
nn[%5%56a< !!&1!5a8 	 GG0dG;rU   c                
  > [        [        U 5      5      nU(       d  g TR                  5         TR                  SSU R                   35        TR                  SST" U R
                  5       S35        U H  nT" U5        M     g )N-zfixtures used by ())r   r)  r  sepr   r  )r   r   r^   r,  r  r>  s      rS   
write_item+_show_fixtures_per_test.<locals>.write_item  sp    1$78
	
s'		{34
sa(78:;%J*% &rU   r  )r  r  r   r   )r   r  r   r   )_pytest.configperform_collectinvocation_paramsr  r  create_terminal_writerget_verbosityr   )
r  rN   rr   rE  session_itemr,  r!  r  r=  r>  s
        @@@@@rS   r  r    sv    --11N		.	.v	6B""$G6< <&& &  <  &rU   c                (    SSK Jn  U" U [        5      $ r  )r  r  _showfixtures_mainr  s     rS   r  r    s    ) 233rU   c           
     4   SS K nUR                  5         U R                  R                  nUR                  R                  U 5      nU R                  5       nUR                  n/ n[        5       nUR                  R                  5        H  u  pU
c   eU
(       d  M  U
 H  n[        UR                  U5      nUR                  U4U;   a  M-  UR                  UR                  U45        UR                  [!        UR"                  5      UR                  R$                  ['        X;R                  5      UR                  U45        M     M     UR)                  5         S nU GH7  u  pnpX:w  a=  UR+                  S5      (       d'  UR-                  5         UR/                  SSU 35        UnUS::  a  U	R+                  S5      (       a  Mh  UR1                  U	 SS9  UR2                  S:w  a  UR1                  S	UR2                   S
3SS9  UR1                  SU 3SS9  UR1                  S5        [4        R6                  " UR                  5      nU(       a%  [9        XES::  a  UR;                  SSS9S   OU5        OUR-                  SSS9  UR-                  5         GM:     g )Nr   z_pytest.rA  zfixtures defined from r   Tr/  r  z [z scope])cyanr1  r2  r  r4  r   r5  r7  r  )rG  rH  rI  r  r  rJ  rK  rR   r   r   r   r%   rm  r~   r   r  rf   r]   r   r$  sortre   r  rD  r8  rq   rf  r9  r:  r  )r  rN   rr   r!  r  r=  r  r  seenr~   r   r^   r"  currentmoduler]   r%  r;  docs                     rS   rN  rN    sF   --11N		.	.v	6B""$G		 	 BI!$D " 3 3 9 9 ;&&&%Jjoo~>C""C(D0HHj((#./
))*OO..(I&& &	 !<& NNM;D7
G"$$Z00	s4VH=> &a<G..s33
G9T*z)HHr***+73$H?
4
|$T2
nnZ__-1CIIfqI1!4# GG0dG;
	) <ErU   c                Z    UR                  S5       H  nU R                  X#-   5        M     g )Nr  )r  r  )r  rT  r  r  s       rS   r:  r:  	  s"    		$
  rU   )rq   rU  r  rS  c           
     V    UR                   R                  R                  U UUUUUUS9  g)a*  Register a fixture imperatively.

This is an advanced function intended for use by plugins.

Normally, fixtures should be registered declaratively using the
:func:`@pytest.fixture <pytest.fixture>` decorator. Pytest looks for these
fixture definitions during the collection phase and registers them
automatically. For some plugin usecases the declarative interface can be
cumbersome or nonviable, in which case the imperative interface can be used.

Fixture registration is expected to happen during the collection phase, and
this is the only sanctioned use. However, to allow for more creative uses,
this is not enforced. But do so at your own risk!

.. versionadded: 9.1

:param name:
    The fixture's name.
:param func:
    The fixture's implementation function.
:param node:
    The visibility of the fixture.

    Only items that are descendents of this node in the collection tree will
    be able to request this fixture. You can think of this as the place
    where you would put the `@pytest.fixture`.

    For global visibility, pass the :class:`session <pytest.Session>` node,
    which is the root of the collection tree.
:param scope:
    The fixture's scope.
:param params:
    The fixture's parametrization params.
:param ids:
    The fixture's IDs.
:param autouse:
    Whether this is an autouse fixture.
r   rm  r[   rq   rU  r  rS  N)rN   rR   r  rW  s          rS   register_fixturerX  	  s7    ` 	LL  22 3 rU   r  )r[   r  r^   r  r   nodes.Node | None)rg   FixtureDef[Any]rh   rZ  r   r  )r[   r  rq   rB   r   rY  )rw   r<  r   zFixtureFunctionMarker | None)r   r  rq   rB   r   zIterator[ParamArgKey])r   zSequence[nodes.Item]r   r  )
r   OrderedSet[nodes.Item]r   z<Mapping[Scope, Mapping[nodes.Item, OrderedSet[ParamArgKey]]]r   zCMapping[Scope, Mapping[ParamArgKey, OrderedDict[nodes.Item, None]]]rq   rB   r   r[  )r   Iterable[str]r   z1Callable[[str], Sequence[FixtureDef[Any]] | None]r   r   )r  r8  rP  r   r   rL   r   )r  z"Callable[[str, Config], ScopeName]r   r}   r  r,   r   rC   )r^   FixtureDef[FixtureValue]rP  r   r   r8  )r^   r]  rP  rJ  r   rL   )rv  zCallable[..., object]rq   rR  rU  Iterable[object] | NonerS  r  r  ?Sequence[object | None] | Callable[[Any], object | None] | Noner   r~  r   ru   ).)rv  r   rq   rR  rU  r^  rS  r  r  r_  r   r~  r   rQ  rP   )rv  zFixtureFunction | Nonerq   rR  rU  r^  rS  r  r  r_  r   r~  r   z1FixtureFunctionMarker | FixtureFunctionDefinition)rP  r   r   r,   )r  r/   r   r   )r  r,   r   zint | ExitCode | None)r   r  r  zbool | Sequence[str]r\   r}   r   z(dict[str, Literal['indirect', 'direct']])r[   r  r   zset[str])r  r\  r   r   )r  r,   r   zint | ExitCode)r!  r   r   r}   )r'  r  r   zIterator[FixtureDef[object]])r  r,   rN   r9   r   r   )z    )r  r   rT  r}   r  r}   r   r   )r   r}   rm  r  r[   r  rq   rR  rU  r9  r  r:  rS  r  r   r   )
__future__r   r  collectionsr   r   r   collections.abcr   r   r	   r
   r   r   r   r   AbstractSetdataclassesr  rf  r  pathlibr   r   r  typingr   r   r   r   r   r   r   r   r   r   rY  rr   r   _pytest._coder   r   _pytest._code.coder   r   _pytest._ior   _pytest.compatr    r!   r"   r#   r$   r%   r&   r'   r(   r)   r*   rG  r+   r,   r-   r.   _pytest.config.argparsingr/   _pytest.deprecatedr1   r2   r3   r4   r5   r6   r7   r8   r  r9   _pytest.markr:   _pytest.mark.structuresr;   _pytest.outcomesr<   r=   r>   _pytest.pathlibr?   r@   _pytest.scoperA   rB   rC   _pytest.warning_typesrD   version_infoexceptiongrouprG   rX   rH   rI   rJ   _pytest.reportsrK   rL   r<  r^  _FixtureFuncrz  r  TracebackType_FixtureCachedResultrT   r`   ri   rs   rx   	dataclassr{   r   r   
OrderedSetr   r   r   r   r   ABCr   r  rJ  LookupErrorr<  r  r  r  r  r  rT  rH  r+  rQ  ru   rw  r~  r  r  r  r  r  r  rQ   r  __file__r_   r   r$  r)  r  r  rN  r:  rX  r   rU   rS   <module>r~     s   " 
 #  # $ % $ $ # * $ .    	  
                %   5 + & ' % ( * $ & ! % ' ' $ ( ! # # , - < 8 F 8 A ? ,   % 1 ! ! ) ( ' %  # / g1 (''- ~63;'\)*Xc9\;R6R-SS 
	 mU004778		: $6
" "'6	24 d#  $$ T]"d(^
L<*>!>Q>> > >B-,-, F-, 	-,` d#/Y /Y $/YdGSWW GT
 &* &* &*R S1 S1 S1l 6R 6R 6RrF\ FD+6D$
$6  	.Cd& CdL
>2 .(3AD!(!3=!!H d#'" '" $ '"V-& -&` 
 =@&)KN$+$ :$ $	$
 $ 
I$ $ $ 
$ 
   =@&)KN   :  $	 
   
I      
  04H =G&*KOH,H :H $	H
 H 
IH H 7HV Z
  		4 	y 4$$"$ $ .	$N 0FY! Y!x9 7##$++0<.!b46r =G&*MQ8
8 8 	8
 :8 $8 
K8 8 
8rU   