← Back
Editing: test_procmontap.cpython-38.pyc
U W[� � @ sJ d Z ddlmZ ddlmZ ddlmZ ddlmZ G dd� dej �ZdS ) z) Tests for L{twisted.runner.procmontap}. � )� UsageError)�unittest)�ProcessMonitor)� procmontapc @ 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 �E/usr/lib/python3/dist-packages/twisted/runner/test/test_procmontap.py�test_commandLineRequired s z/ProcessMonitorTapTests.test_commandLineRequiredc C s, t �� }|�dddg� | �|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 �� }|�dddg� | �|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&