ó
    Ö›‘h

  ã                   ób   • S r SSKJr  SSKJr  SSKJr  SSKJ	r	   " S S\	R                  5      rg)	z)
Tests for L{twisted.runner.procmontap}.
é    )Ú
UsageError)Ú
procmontap)ÚProcessMonitor)Úunittestc                   ó^   • \ rS rSrS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rg)ÚProcessMonitorTapTestsé   zQ
Tests for L{twisted.runner.procmontap}'s option parsing and makeService
method.
Nc                 óp   • [         R                  " 5       nU R                  [        UR                  / 5        g)z.
The command line arguments must be provided.
N)ÚtapÚOptionsÚassertRaisesr   ÚparseOptions©ÚselfÚopts     ÚgC:\Users\psant\Downloads\Noiseback\school\venv\Lib\site-packages\twisted/runner/test/test_procmontap.pyÚtest_commandLineRequiredÚ/ProcessMonitorTapTests.test_commandLineRequired   s'   € ô �kŠk‹mˆØ×Ñœ* c×&6Ñ&6¸Õ;ó    c                 ó~   • [         R                  " 5       nUR                  / SQ5        U R                  US   S5        g)zI
The threshold option is recognised as a parameter and coerced to
float.
)z--thresholdú7.5ÚfooÚ	thresholdç      @N©r   r   r   ÚassertEqualr   s     r   Útest_thresholdÚ%ProcessMonitorTapTests.test_threshold   s3   € ô
 �kŠk‹mˆØ×ÑÒ6Ô7Ø×Ñ˜˜[Ñ)¨3Õ/r   c                 ó~   • [         R                  " 5       nUR                  / SQ5        U R                  US   S5        g)zH
The killtime option is recognised as a parameter and coerced to float.
)z
--killtimer   r   Úkilltimer   Nr   r   s     r   Útest_killTimeÚ$ProcessMonitorTapTests.test_killTime$   s2   € ô �kŠk‹mˆØ×ÑÒ5Ô6Ø×Ñ˜˜Z™¨#Õ.r   c                 ó~   • [         R                  " 5       nUR                  / SQ5        U R                  US   S5        g)zO
The minrestartdelay option is recognised as a parameter and coerced to
float.
)z--minrestartdelayr   r   Úminrestartdelayr   Nr   r   s     r   Útest_minRestartDelayÚ+ProcessMonitorTapTests.test_minRestartDelay,   ó4   € ô
 �kŠk‹mˆØ×ÑÒ<Ô=Ø×Ñ˜Ð.Ñ/°Õ5r   c                 ó~   • [         R                  " 5       nUR                  / SQ5        U R                  US   S5        g)zO
The maxrestartdelay option is recognised as a parameter and coerced to
float.
)z--maxrestartdelayr   r   Úmaxrestartdelayr   Nr   r   s     r   Útest_maxRestartDelayÚ+ProcessMonitorTapTests.test_maxRestartDelay5   r'   r   c                 óú   • [         R                  " 5       nUR                  S/5        U R                  US   S5        U R                  US   S5        U R                  US   S5        U R                  US   S5        g	)
z(
The parameters all have default values
r   r   é   r    é   r$   r)   i  Nr   r   s     r   Útest_parameterDefaultsÚ-ProcessMonitorTapTests.test_parameterDefaults>   st   € ô �kŠk‹mˆØ×Ñ˜%˜Ô!Ø×Ñ˜˜[Ñ)¨1Ô-Ø×Ñ˜˜Z™¨!Ô,Ø×Ñ˜Ð.Ñ/°Ô3Ø×Ñ˜Ð.Ñ/°Õ6r   c                 óä   • [         R                  " 5       nUR                  / SQ5        [         R                  " U5      nU R	                  U[
        5        U R                  SUR                  5        g)z@
The command line gets added as a process to the ProcessMontor.
)Úpingz-cÚ3z8.8.8.8zping -c 3 8.8.8.8N)r   r   r   ÚmakeServiceÚassertIsInstancer   ÚassertInÚ	processes)r   r   Úss      r   Útest_makeServiceÚ'ProcessMonitorTapTests.test_makeServiceI   sO   € ô �kŠk‹mˆØ×ÑÒ7Ô8Ü�OŠO˜CÓ ˆØ×Ñ˜a¤Ô0Ø�‰Ð)¨1¯;©;Õ7r   © )ÚreturnN)Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__r   r   r!   r%   r*   r/   r9   Ú__static_attributes__r;   r   r   r   r      s*   † ñô
<ô0ô/ô6ô6ô	7÷8r   r   N)rA   Útwisted.python.usager   Útwisted.runnerr   r   Útwisted.runner.procmonr   Útwisted.trialr   ÚTestCaser   r;   r   r   Ú<module>rH      s,   ðñõ ,Ý ,Ý 1Ý "ôC8˜X×.Ñ.õ C8r   