Файловый менеджер - Редактировать - /opt/imh-python/lib/python3.9/site-packages/twisted/runner/test/__pycache__/test_procmontap.cpython-39.pyc
Ðазад
a k�h� � @ sJ d Z ddlmZ ddlmZ ddlmZ ddlm Z G dd� de j �ZdS ) z) Tests for L{twisted.runner.procmontap}. � )� UsageError)� procmontap)�ProcessMonitor)�unittestc @ sH e Zd ZdZdd� Zdd� Zdd� Zdd � Zd d� Zdd � Z dd� Z dS )�ProcessMonitorTapTestsz] Tests for L{twisted.runner.procmontap}'s option parsing and makeService method. c C s t �� }| �t|jg � dS )z> The command line arguments must be provided. N)�tap�OptionsZassertRaisesr �parseOptions��self�opt� r ��/root/rpmbuild/BUILDROOT/imh-python39-modules-3.9.7-92.el8.x86_64/opt/imh-python/lib/python3.9/site-packages/twisted/runner/test/test_procmontap.py�test_commandLineRequired s z/ProcessMonitorTapTests.test_commandLineRequiredc C s* t �� }|�g d�� | �|d d� dS )za The threshold option is recognised as a parameter and coerced to float. )z--threshold�7.5�foo� threshold� @N�r r r ZassertEqualr r r r �test_threshold s z%ProcessMonitorTapTests.test_thresholdc C s* t �� }|�g d�� | �|d d� dS )zX The killtime option is recognised as a parameter and coerced to float. )z --killtimer r �killtimer Nr r r r r � test_killTime$ s z$ProcessMonitorTapTests.test_killTimec C s* t �� }|�g d�� | �|d d� dS )zg The minrestartdelay option is recognised as a parameter and coerced to float. )z--minrestartdelayr r �minrestartdelayr Nr r r r r �test_minRestartDelay, s z+ProcessMonitorTapTests.test_minRestartDelayc C s* t �� }|�g d�� | �|d d� dS )zg The maxrestartdelay option is recognised as a parameter and coerced to float. )z--maxrestartdelayr r �maxrestartdelayr Nr r r r r �test_maxRestartDelay5 s z+ProcessMonitorTapTests.test_maxRestartDelayc C sX t �� }|�dg� | �|d d� | �|d d� | �|d d� | �|d d� d S ) z8 The parameters all have default values r r � r � r r i Nr r r r r �test_parameterDefaults>