| Server IP : 65.1.209.187 / Your IP : 216.73.216.144 Web Server : nginx/1.24.0 System : Linux ip-172-31-5-206 6.14.0-1015-aws #15~24.04.1-Ubuntu SMP Tue Sep 23 22:44:48 UTC 2025 x86_64 User : ( 1001) PHP Version : 8.3.6 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /lib/python3/dist-packages/twisted/trial/test/__pycache__/ |
Upload File : |
�
oj � �t � d Z ddlZddlmZ ddlmZ ddlmZ G d� d� Z G d� d eej � Z
y)
z2
Tests for warning suppression features of Trial.
� N)�namedAny)�unittest)�suppressionc �F � e Zd ZdZd� Zd� Zd� Zd� Zd� Zd� Z d� Z
d � Zd
� Zy)�SuppressionMixinzj
Tests for the warning suppression features of
L{twisted.trial.unittest.SynchronousTestCase}.
c �J � |j t j � � y )N)�run�pyunit�
TestResult)�self�suites �E/usr/lib/python3/dist-packages/twisted/trial/test/test_suppression.py�runTestszSuppressionMixin.runTests s � �
� � �&�#�#�%�&� c �: � t j ||� g� S )z�
Return a new L{unittest.TestSuite} with a single test method in it.
@param cls: A L{TestCase} subclass defining a test method.
@param methodName: The name of the test method from C{cls}.
)r
� TestSuite)r �cls�
methodNames r �_loadzSuppressionMixin._load s � � ����Z�� 1�2�2r c �T � | j |D �cg c] }|d �� c}|� yc c}w )a&
Assert that a certain number of warnings with certain messages were
emitted in a certain order.
@param warnings: A list of emitted warnings, as returned by
C{flushWarnings}.
@param which: A list of strings giving warning messages that should
appear in C{warnings}.
@raise self.failureException: If the warning messages given by C{which}
do not match the messages in the warning information in C{warnings},
or if they do not appear in the same order.
�messageN)�assertEqual)r �warnings�which�warnings r �_assertWarningsz SuppressionMixin._assertWarnings# s'