| Server IP : 13.235.167.51 / Your IP : 216.73.217.116 Web Server : Apache System : Linux machinox-server 6.17.0-1013-aws #13~24.04.1-Ubuntu SMP Fri Apr 24 21:36:58 UTC 2026 aarch64 User : root ( 0) PHP Version : 8.2.29 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /lib/python3/dist-packages/twisted/test/__pycache__/ |
Upload File : |
�
oj
� �� � d Z ddlZddlZddlmZ ddlZdZddlm Z ddl
mZmZ G d� d � Z
e j e
� G d
� de� Z G d� d
e� Zy# e$ r dZY �Jw xY w)z)
Tests for L{twisted.python.threadable}.
� N)�skipIfFT)�
threadable)�FailTest�SynchronousTestCasec � � e Zd ZdgZdZdZd� Zy)�
TestObject�aMethod���� c �� � t d� D ]g }| j | j c| _ | _ | j | j z | _ | j dk( r�TJ d| j fz � � y )N�
r zz == %d, not 0 as expected)�range�y�x�z)�self�is �>/usr/lib/python3/dist-packages/twisted/test/test_threadable.pyr zTestObject.aMethod sb � ��r�� I�A�!�V�V�T�V�V�N�D�F�D�F��V�V�d�f�f�_�D�F��6�6�Q�;�H� <����y� H�H�;� I� N)�__name__�
__module__�__qualname__�synchronizedr r r � r r r r s � ��;�L�
�A� �A�Ir r c �Z � e Zd Zd� Zd� Z eed� d� � Z eed� d� � Zd� Z y)�SynchronizationTestsc � � | j t j t j � � t j d� y)z�
Reduce the CPython check interval so that thread switches happen much
more often, hopefully exercising more possible race conditions. Also,
delay actual test startup until the reactor has been started.
gH�����z>N)�
addCleanup�sys�setswitchinterval�getswitchinterval�r s r �setUpzSynchronizationTests.setUp) s/ � �
����-�-�s�/D�/D�/F�G����i�(r c �X � | j dt j j � y)zk
The name of a synchronized method is inaffected by the synchronization
decorator.
r N)�assertEqualr r r r"