HEX
Server: Apache
System: Linux pdx1-shared-a1-29 6.18.39-grsec-noble+ #4 SMP Thu Jul 23 07:53:29 UTC 2026 x86_64
User: dh_bj99yp (22285841)
PHP: 8.3.30
Disabled: NONE
Upload Files
File: //lib/python3/dist-packages/genshi/template/tests/__pycache__/eval.cpython-312.pyc
�

EMab����ddlZddlZddlZddlZddlmZddlZddlmZddl	m
Z
ddlmZm
Z
mZmZmZddlmZmZmZGd�dej*�ZGd	�d
ej*�Zd�Zedk(rej4d
��yy)�N)�mkstemp)�Markup)�Context)�
Expression�Suite�	Undefined�UndefinedError�	UNDEFINED)�BytesIO�
IS_PYTHON2�
wrapped_bytesc���eZdZd�Zd�Zd�Zd�Zd�Zd�Zd�Z	d�Z
d	�Zd
�Zd�Z
d�Zd
�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Z d �Z!d!�Z"d"�Z#d#�Z$d$�Z%d%�Z&d&�Z'd'�Z(d(�Z)d)�Z*d*�Z+d+�Z,d,�Z-d-�Z.d.�Z/d/�Z0d0�Z1d1�Z2d2�Z3d3�Z4e5jld4k\rd5�Z7d6�Z8d7�Z9d8�Z:d9�Z;d:�Z<d;�Z=d<�Z>d=�Z?d>�Z@d?�ZAd@�ZBdA�ZCdB�ZDdC�ZEdD�ZFdE�ZGdF�ZHdG�ZIdH�ZJdI�ZKdJ�ZLdK�ZMdL�ZNyM)N�ExpressionTestCasec��td�}|j|td��|j|td��y�Nzx,yzy, x)r�assertEqual�assertNotEqual��self�exprs  �</usr/lib/python3/dist-packages/genshi/template/tests/eval.py�test_eqzExpressionTestCase.test_eqs6���%� ������z�%�0�1����D�*�V�"4�5�c���td�}|jt|�ttd���|jt|�ttd���yr)rr�hashrrs  r�	test_hashzExpressionTestCase.test_hash#sH���%� ������d��T�*�U�*;�%<�=����D��J��Z��-?�(@�Arc��td�}t�}tj||d�|j	d�tj
|�}|j
i�dusJ�|j|jk(sJ�y)N�1 < 2�rT)rr�pickle�dump�seek�load�evaluate�code)rr�buf�	unpickleds    r�test_picklezExpressionTestCase.test_pickle(sk���'�"���i�����D�#�q�!�������K�K��$�	��!�!�"�%��-�-�-��~�~����*�*�*rc�h�|jdtd�jddi��|jttd�ji��|jdtd�jddi��|jdtd�jddi��y)N�bar�foo�id)rrr$r,�rs r�test_name_lookupz#ExpressionTestCase.test_name_lookup1s�������
�5� 1� :� :�E�5�>� J�K�����Z��-�6�6�r�:�;�����
�4� 0� 9� 9�4��-� H�I�����z�$�/�8�8�$���F�Grc�d�td�}|j|ji�t�y)Nr)rrr$rrs  r�
test_builtinsz ExpressionTestCase.test_builtins7s%���(�#��������r�*�F�3rc�,�|jdtd�ji��|jdtd�ji��|jdjd�tt	d��ji��|jdtd�ji��|jdtd�ji��|jdtd�ji��y)	Nr+z"foo"z	"""foo"""�utf-8zb'foo'z	'''foo'''zu'foo'zr'foo')rrr$�encoder
r-s r�test_str_literalz#ExpressionTestCase.test_str_literal;s�������
�7� 3� <� <�R� @�A�����
�;� 7� @� @�� D�E�������w�/�#�M�(�$;�<�E�E�b�I�	K�����
�;� 7� @� @�� D�E�����
�8� 4� =� =�b� A�B�����
�8� 4� =� =�b� A�Brc��td�}|jd|ji��td�}|jd|ji��ttd��}tr"|jd|ji��y|jdjd�|ji��y)Nuu'þ'�þzb'\xc3\xbe'r2)rrr$r
rr3rs  r�test_str_literal_non_asciiz-ExpressionTestCase.test_str_literal_non_asciiDs����*�%�������
�
�b� 1�2��)�$�������
�
�b� 1�2�
�-��7�8������U�D�M�M�"�$5�6����U�\�\�'�2�D�M�M�"�4E�Frc��|jdtd�ji��tr*|jdtd�ji��|jdtd�ji��tr*|jdtd�ji��|jdtd	�ji��|jdtd
�ji��y)N�*�42�42Lg�z�G��?z.42��07���0xF2�0XF2)rrr$rr-s r�test_num_literalz#ExpressionTestCase.test_num_literalSs�������Z��-�6�6�r�:�;�����R��E�!2�!;�!;�B�!?�@�����j��/�8�8��<�=�����Q�
�4� 0� 9� 9�"� =�>�����z�&�1�:�:�2�>�?�����z�&�1�:�:�2�>�?rc��|jitd�ji��|jdditd�jddi��y)Nz{}�keyTz{'key': value}�value�rrr$r-s r�test_dict_literalz$ExpressionTestCase.test_dict_literal]sO������Z��-�6�6�r�:�;����%���#�$4�5�>�>����O�	Qrc�
�|jgtd�ji��|jgd�td�ji��|jdgtd�jddi��y)Nz[]��r�z	[1, 2, 3]Tz[value]rDrEr-s r�test_list_literalz$ExpressionTestCase.test_list_literalbsl������Z��-�6�6�r�:�;�����J�{�$;�$D�$D�R�$H�I����$��#�I�.�7�7��$��H�	Jrc��|jdtd�ji��|jdtd�ji��|jdtd�jddi��y)	N�z()rHz	(1, 2, 3))Tz(value,)rDTrEr-s r�test_tuple_literalz%ExpressionTestCase.test_tuple_literalhsj������Z��-�6�6�r�:�;�����J�{�$;�$D�$D�R�$H�I�����#�J�/�8�8�'�4��I�	Krc��|jdtd�ji��|jdtd�jddi��y)NrIz+1z+x�xrEr-s r�test_unaryop_posz#ExpressionTestCase.test_unaryop_posnsF������J�t�,�5�5�b�9�:�����J�t�,�5�5�s�A�h�?�@rc��|jdtd�ji��|jdtd�jddi��y)N���z-1z-xrPrIrEr-s r�test_unaryop_negz#ExpressionTestCase.test_unaryop_negr�F������Z��-�6�6�r�:�;�����Z��-�6�6��Q�x�@�Arc��|jdtd�ji��|jdtd�jddi��y)NFznot Trueznot xrPTrEr-s r�test_unaryop_notz#ExpressionTestCase.test_unaryop_notvsF������
�:� 6� ?� ?�� C�D�����
�7� 3� <� <�c�4�[� I�Jrc��|jdtd�ji��|jdtd�jddi��y)N���z~1z~xrPrIrEr-s r�test_unaryop_invz#ExpressionTestCase.test_unaryop_invzrUrc��|jdtd�ji��|jdtd�jddd���y)NrJz2 + 1zx + yrrI�rP�yrEr-s r�test_binop_addz!ExpressionTestCase.test_binop_add~�G������J�w�/�8�8��<�=�����J�w�/�8�8�q�q�9I�J�Krc��|jdtd�ji��|jdtd�jddd���y)NrI�2 - 1�x - yr\rEr-s r�test_binop_subz!ExpressionTestCase.test_binop_sub�r_rc��|jdtd�ji��|jdtd�jddd���y)NrIrarbrr\rEr-s rrcz!ExpressionTestCase.test_binop_sub�r_rc��|jdtd�ji��|jdtd�jddd���y)N�z2 * 2zx * yrr\rEr-s r�test_binop_mulz!ExpressionTestCase.test_binop_mul�r_rc��|jdtd�ji��|jdtd�jddd���y)Nrfz2 ** 2zx ** yrr\rEr-s r�test_binop_powz!ExpressionTestCase.test_binop_pow��G������J�x�0�9�9�"�=�>�����J�x�0�9�9���:J�K�Lrc��|jdtd�ji��|jdtd�jddd���y)Nrz4 / 2zx / yrfr\rEr-s r�test_binop_divz!ExpressionTestCase.test_binop_div�r_rc��|jdtd�ji��|jdtd�jddd���y)NrIz3 // 2zx // yrJrr\rEr-s r�test_binop_floordivz&ExpressionTestCase.test_binop_floordiv�rjrc��|jdtd�ji��|jdtd�jddd���y)NrIz3 % 2zx % yrJrr\rEr-s r�test_binop_modz!ExpressionTestCase.test_binop_mod�r_rc��|jdtd�ji��|jdtd�jddd���y)Nrz1 & 0zx & yrIr\rEr-s r�test_binop_andz!ExpressionTestCase.test_binop_and�r_rc��|jdtd�ji��|jdtd�jddd���y)NrIz1 | 0zx | yrr\rEr-s r�
test_binop_orz ExpressionTestCase.test_binop_or�r_rc��|jdtd�ji��|jdtd�jddd���y)NrIz1 ^ 0zx ^ yrr\rEr-s r�test_binop_xorz!ExpressionTestCase.test_binop_xor�r_rc��|jdtd�ji��|jdtd�jddd���y)NTz1 in (1, 2, 3)zx in yrIrHr\rEr-s r�test_binop_containsz&ExpressionTestCase.test_binop_contains�sR������z�*:�;�D�D�R�H�I�����z�(�3�<�<�1�CL�>N� O�	Prc��|jdtd�ji��|jdtd�jddd���y)NTz4 not in (1, 2, 3)z
x not in yrfrHr\rEr-s r�test_binop_not_containsz*ExpressionTestCase.test_binop_not_contains�sS������z�*>�?�H�H��L�M�����z�,�7�@�@�q�GP�BR� S�	Trc�`�|jdtd�ji��|jdtd�jddd���|jdtd�ji��|jdtd�jddd���y)	NTz1 is 1zx is yrIr\Fz1 is 2rrEr-s r�
test_binop_isz ExpressionTestCase.test_binop_is�s�������z�(�3�<�<�R�@�A�����z�(�3�<�<�1�1�=M�N�O�����
�8� 4� =� =�b� A�B�����
�8� 4� =� =�A�A�>N� O�Prc�`�|jdtd�ji��|jdtd�jddd���|jdtd�ji��|jdtd�jddd���y)	NTz
1 is not 2z
x is not yrIrr\Fz
1 is not 1rEr-s r�test_binop_is_notz$ExpressionTestCase.test_binop_is_not�s�������z�,�7�@�@��D�E�����z�,�7�@�@�q�GH�BJ� K�	L�����
�<� 8� A� A�"� E�F�����
�<� 8� A� A��HI�CK�!L�	Mrc��|jdtd�ji��|jdtd�jddd���y)NFzTrue and Falsezx and yTr\rEr-s r�test_boolop_andz"ExpressionTestCase.test_boolop_and�sS������
�+;� <� E� E�b� I�J�����
�9� 5� >� >�T�EJ�@L�!M�	Nrc��|jdtd�ji��|jdtd�jddd���y)NTz
True or Falsezx or yFr\rEr-s r�test_boolop_orz!ExpressionTestCase.test_boolop_or�sQ������z�/�:�C�C�B�G�H�����z�(�3�<�<�4�CH�>J� K�	Lrc��|jdtd�ji��|jdtd�jddd���y)NTz1 == 1zx == yrIr\rEr-s r�test_compare_eqz"ExpressionTestCase.test_compare_eq��G������z�(�3�<�<�R�@�A�����z�(�3�<�<�1�1�=M�N�Orc��|jdtd�ji��|jdtd�jddd���tjdkrX|jdtd�ji��|jdtd�jddd���yy)	NFz1 != 1zx != yrIr\�3z1 <> 1zx <> y)rrr$�sys�versionr-s r�test_compare_nez"ExpressionTestCase.test_compare_ne�s�������
�8� 4� =� =�b� A�B�����
�8� 4� =� =�A�A�>N� O�P��;�;������U�J�x�$8�$A�$A�"�$E�F����U�J�x�$8�$A�$A��PQ�BR�$S�T�rc��|jdtd�ji��|jdtd�jddd���y)NTrzx < yrIrr\rEr-s r�test_compare_ltz"ExpressionTestCase.test_compare_lt��G������z�'�2�;�;�B�?�@�����z�'�2�;�;�!�!�<L�M�Nrc��|jdtd�ji��|jdtd�jddd���y)NTz1 <= 1zx <= yrIr\rEr-s r�test_compare_lez"ExpressionTestCase.test_compare_le�r�rc��|jdtd�ji��|jdtd�jddd���y)NTz2 > 1zx > yrrIr\rEr-s r�test_compare_gtz"ExpressionTestCase.test_compare_gt�r�rc��|jdtd�ji��|jdtd�jddd���y)NTz1 >= 1zx >= yrIr\rEr-s r�test_compare_gez"ExpressionTestCase.test_compare_ge�r�rc��|jdtd�ji��|jdtd�jddd���y)NTz1 != 3 == 3zx != y == yrIrJr\rEr-s r�test_compare_multiz%ExpressionTestCase.test_compare_multi�sR������z�-�8�A�A�"�E�F�����z�-�8�A�A��HI�CK� L�	Mrc�,�|jdtd�jdd�i��ddi}|jdtd�j|��ddtd�ii}|jdtd�j|��y)	Nr9zfoo()r+c��y)Nr9rMrMrr�<lambda>z7ExpressionTestCase.test_call_function.<locals>.<lambda>�s�rr*�BARzfoo.upper()zlen(foo.bar))rrr$�range�r�datas  r�test_call_functionz%ExpressionTestCase.test_call_function�s�������Z��0�9�9�5�*�:M�N�O��u�~������
�=� 9� B� B�4� H�I���u�R�y�)�*������Z��7�@�@��F�Grc�`�|jdtd�jd�dd���y)Nr9z
foo(x=bar)c��|S�NrM�rPs rr�z7ExpressionTestCase.test_call_keywords.<locals>.<lambda>�s��QR�r�r+r*rEr-s r�test_call_keywordsz%ExpressionTestCase.test_call_keywords�s2������Z��5�>�>�{�GI�@K�L�	Mrc�b�|jdtd�jd�dgd���y)Nr9z	foo(*bar)c��|Sr�rMr�s rr�z8ExpressionTestCase.test_call_star_args.<locals>.<lambda>�s��PQ�rr�rEr-s r�test_call_star_argsz&ExpressionTestCase.test_call_star_args�s3������Z��4�=�=�k�GI�d�?L�M�	Nrc�l�d�}td�}|jd|j|ddid���y)Nc��|Sr�rMr�s rr+z4ExpressionTestCase.test_call_dstar_args.<locals>.foo�s���Hrz
foo(**bar)r9rPr��rrr$)rr+rs   r�test_call_dstar_argsz'ExpressionTestCase.test_call_dstar_args�s3��	��,�'������T�]�]�3��R�y�+I�J�Krc��dtd�i}td�}|jddgt|j	|���y)N�items�zfilter(lambda x: x > 2, items)rJrf)r�rr�listr$�rr�rs   r�test_lambdazExpressionTestCase.test_lambdas=����q��"���:�;�����!�Q���d�m�m�D�&9�!:�;rc��tsydddgi}td�}|jdgt|j	|���y)Nr��rIr)rrIz#filter(lambda (x, y): x > y, items))rrrr�r$r�s   r�test_lambda_tuple_argz(ExpressionTestCase.test_lambda_tuple_argsB�����&�&�)�*���?�@�����&��4��
�
�d�(;�#<�=rc
�N�td�}|jddg|jdtd�i��td�}|jgd�|jdtd�i��td�}|jgd	�|jtd�d
d���td�}|jgd
�|jdtd
�td�gi��td�}|jgd�|jddgddgd���y)Nz[n for n in numbers if n < 2]rrI�numbersr�z+[(i, n + 1) for i, n in enumerate(numbers)]�)rrIr�)rrJ)rJrf)rfr�z[offset + n for n in numbers]�rrJrfr��r�r��offsetz&[n for group in groups for n in group]�rrIrrIr�groupsrJz[(a, b) for a in x for b in y]�)�x0�y0)r��y1)�x1r�)r�r�r�r�r�r�r\�rrr$r�rs  r�test_list_comprehensionz*ExpressionTestCase.test_list_comprehensions���9�:�����!�Q�����	�5��8�/D�!E�F��G�H�����A����	�5��8�'<�=�	?��9�:���������5��8�q�'I�J�	L��B�C����������5��8�U�1�X�2F�'G�H�	J��:�;�����Q����d�D�\��t��'M�N�	Prc�v�ddd�ddd�g}td�}|jdg|jd|i��y)N�arI��namerD�brz&[i.name for i in items if i.value > 1]r�r��rr�rs   r�$test_list_comprehension_with_getattrz7ExpressionTestCase.test_list_comprehension_with_getattr"sA����*�S�1�,E�F���B�C�����#���
�
�w��.>� ?�@rc�v�ddd�ddd�g}td�}|jdg|jd|i��y)Nr�rIr�r�rz,[i['name'] for i in items if i['value'] > 1]r�r�r�s   r�$test_list_comprehension_with_getitemz7ExpressionTestCase.test_list_comprehension_with_getitem'sA����*�S�1�,E�F���H�I�����#���
�
�w��.>� ?�@rc
�N�td�}|jddg|jdtd�i��td�}|jgd�|jdtd�i��td�}|jgd	�|jtd�d
d���td�}|jgd
�|jdtd
�td�gi��td�}|jgd�|jddgddgd���y)Nz!list(n for n in numbers if n < 2)rrIr�r�z/list((i, n + 1) for i, n in enumerate(numbers))r�z!list(offset + n for n in numbers)r�rr�z*list(n for group in groups for n in group)r�r�rJz"list((a, b) for a in x for b in y)r�r�r�r�r�r\r�rs  r�test_generator_expressionz,ExpressionTestCase.test_generator_expression,s���=�>�����!�Q�����	�5��8�/D�!E�F��K�L�����A����	�5��8�'<�=�	?��=�>���������5��8�q�'I�J�	L��F�G����������5��8�U�1�X�2F�'G�H�	J��>�?�����Q����d�D�\��t��'M�N�	Prc�v�ddd�ddd�g}td�}|jdg|jd|i��y)Nr�rIr�r�rz*list(i.name for i in items if i.value > 1)r�r�r�s   r�&test_generator_expression_with_getattrz9ExpressionTestCase.test_generator_expression_with_getattr@sA����*�S�1�,E�F���F�G�����#���
�
�w��.>� ?�@rc�v�ddd�ddd�g}td�}|jdg|jd|i��y)Nr�rIr�r�rz0list(i['name'] for i in items if i['value'] > 1)r�r�r�s   r�&test_generator_expression_with_getitemz9ExpressionTestCase.test_generator_expression_with_getitemEsA����*�S�1�,E�F���L�M�����#���
�
�w��.>� ?�@r)rr�c��td�}|jd|jddi��|jd|jddi��y)Nz'T' if foo else 'F'�Tr+T�FFr�rs  r�test_conditional_expressionz.ExpressionTestCase.test_conditional_expressionKsG���3�4�D����S�$�-�-���
�">�?����S�$�-�-����"?�@rc��td�}|jddg|jdtt	d��i��y)Nznumbers[0:2]rrIr�r��rrr$r�r�rs  r�
test_slicezExpressionTestCase.test_slicePs6���.�)�����!�Q�����	�4��a��>�/J�!K�Lrc��td�}|jttd��ddd��}|j	ddg|�y)Nznumbers[start:end]r�rr�r��start�endrI�rr$r�r�r�rr�ress   r�test_slice_with_varsz'ExpressionTestCase.test_slice_with_varsTs>���.�/���m�m��U�1�X���1�M�N�����!�Q���%rc��td�}|jdttd��i�}|j	gd�|�y)Nz
numbers[:]r�r��rrIrrJrfr�r�s   r�test_slice_copyz"ExpressionTestCase.test_slice_copyYs7���,�'���m�m�Y��U�1�X��7�8������#�.rc��td�}|jttd��dd��}|j	gd�|�y)Nznumbers[::stride]r�r�r��stride�rrrfr�r�s   r�test_slice_stridez$ExpressionTestCase.test_slice_stride^s8���-�.���m�m��U�1�X��!�D�E������C�(rc��td�}|jdg|jdtt	d��i��y)Nznumbers[-1:]rfr�r�r�rs  r�test_slice_negative_startz,ExpressionTestCase.test_slice_negative_startcs4���.�)�����!��d�m�m�Y��U�1�X��,G�H�Irc��td�}|jdttd��i�}|j	gd�|�y)Nznumbers[:-1]r�r��rrIrrJr�r�s   r�test_slice_negative_endz*ExpressionTestCase.test_slice_negative_endgs7���.�)���m�m�Y��U�1�X��7�8������s�+rc��td�}|jdttd��i�}|j	|d�y)Nz
numbers[1]r�r�rIr�r�s   r�test_slice_constantz&ExpressionTestCase.test_slice_constantls7���,�'���m�m�Y��U�1�X��7�8������a� rc��d�}td�}|jttd��|d��}|j	|d�y)Nc��y�NrrMrMrr�fz-ExpressionTestCase.test_slice_call.<locals>.fr���rznumbers[f()]r��r�r�rr�)rr�rr�s    r�test_slice_callz"ExpressionTestCase.test_slice_callqs<��	��.�)���m�m��U�1�X��Q�?�@������a� rc��td�}|jttd��dd��}|j	|d�y)Nz
numbers[v]r�r�r��vr�r�s   r�test_slice_namez"ExpressionTestCase.test_slice_namexs7���,�'���m�m��U�1�X��Q�?�@������a� rc��Gd�d�}td�}|jttd��|�d��}|j	|d�y)Nc��eZdZd�Zy)�<ExpressionTestCase.test_slice_attribute.<locals>.ValueHolderc��d|_y�NrJ�rDr-s r�__init__zEExpressionTestCase.test_slice_attribute.<locals>.ValueHolder.__init__�	����
rN��__name__�
__module__�__qualname__rrMrr�ValueHolderr�~���
rrznumbers[obj.value]r��r��objrJr�)rrrr�s    r�test_slice_attributez'ExpressionTestCase.test_slice_attribute}sF��	�	��.�/���m�m��U�1�X��{�}�M�N������a� rc���tdddd��}|ji�}t|t�sJ�|j	d|j
�|jtusJ�y)N�nothing�
index.html�2�lenient��filename�lineno�lookup)rr$�
isinstancerr�_name�_ownerr
)rr�retvals   r�test_access_undefinedz(ExpressionTestCase.test_access_undefined�sY���)�l�2�!*�,�����r�"���&�)�,�,�,�����F�L�L�1��}�}�	�)�)�)rc���Gd�dt�}|�}tdddd��}|jd|i�}t|t�sJ�|jd	|j�|j|usJ�y)
Nc��eZdZd�Zy)�<ExpressionTestCase.test_getattr_undefined.<locals>.Somethingc��y�Nz<Something>rMr-s r�__repr__zEExpressionTestCase.test_getattr_undefined.<locals>.Something.__repr__����$rN�rrrr rMrr�	Somethingr����
%rr#�
something.nilrrrr�	something�nil��objectrr$rrrrr�rr#r&rrs     r�test_getattr_undefinedz)ExpressionTestCase.test_getattr_undefined�ss��	%��	%��K�	��/�L��!*�,������Y�7�8���&�)�,�,�,��������-��}�}�	�)�)�)rc���Gd�dt�}|jttd�jd|�i�|jt
td�jd|�i�y)Nc�8�eZdZd�Zee�Zd�Zee�Zy)�<ExpressionTestCase.test_getattr_exception.<locals>.Somethingc��t�r���NotImplementedErrorr-s r�prop_azCExpressionTestCase.test_getattr_exception.<locals>.Something.prop_a����)�)rc��t�r�)�AttributeErrorr-s r�prop_bzCExpressionTestCase.test_getattr_exception.<locals>.Something.prop_b�s��$�$rN)rrrr2�propertyr6rMrrr#r.�s ��
*��f�%�F�
%��f�%�Frr#zs.prop_a�szs.prop_b)r)�assertRaisesr1rr$r5�rr#s  r�test_getattr_exceptionz)ExpressionTestCase.test_getattr_exception�sa��	&��	&�	
���-�$�Z�0�9�9�C���;M�	O����.�$�Z�0�9�9�C���;M�	Orc���Gd�dt�}|�}tdddd��}|jd|i�}t|t�sJ�|jd	|j�|j|usJ�y)
Nc��eZdZd�Zy)�CExpressionTestCase.test_getitem_undefined_string.<locals>.Somethingc��yrrMr-s rr zLExpressionTestCase.test_getitem_undefined_string.<locals>.Something.__repr__�r!rNr"rMrrr#r>�r$rr#�something["nil"]rrrrr&r'r(r*s     r�test_getitem_undefined_stringz0ExpressionTestCase.test_getitem_undefined_string�st��	%��	%��K�	��,�|�B�!*�,������Y�7�8���&�)�,�,�,��������-��}�}�	�)�)�)rc��Gd�dt�}|jttd�jd|�i�y)Nc��eZdZd�Zy)�<ExpressionTestCase.test_getitem_exception.<locals>.Somethingc��t�r�r0)rrCs  r�__getitem__zHExpressionTestCase.test_getitem_exception.<locals>.Something.__getitem__�r3rN)rrrrFrMrrr#rD�s��
*rr#zs["foo"]r8)r)r9r1rr$r:s  r�test_getitem_exceptionz)ExpressionTestCase.test_getitem_exception�s9��	*��	*�	
���-�$�Z�0�9�9�C���;M�	Orc��tdddd��}	|ji�|jd�y#t$�r}t	j
�\}}}|j}g}|jr*|j}|j|�|jr�*|jdt|��|jd|d	jjj�|jd|d	jjj�|jd|d	j�Yd}~yd}~wwxYw)
Nrrr�strictr�Expected UndefinedErrorz"nothing" not definedz<Expression 'nothing'>���)rr$�failr	r��exc_info�tb_next�appendr�str�tb_frame�f_code�co_name�co_filename�	tb_lineno)rr�e�exc_type�	exc_value�
exc_traceback�frame�framess        r�test_error_access_undefinedz.ExpressionTestCase.test_error_access_undefined�s���)�l�2�!)�+��	7��M�M�"���I�I�/�0���	7�14����.�H�i��!�)�)�E��F��-�-��
�
���
�
�e�$��-�-�
���4�c�!�f�=����5�#�B�Z�0�0�7�7�?�?�
A����\�#�B�Z�0�0�7�7�C�C�
E����R����!5�!5�6�6��	7�s�"4�
E�AD?�B D?�?Ec�j�Gd�dt�}tdddd��}	|jd|�i�|jd	�y#t$r�}|jd
t
|��tj�\}}}d}|j}|jr?|j}|jj}	|	j|k(rn|jr�?|jd�|jd	j�|jd|j�Yd}~yd}~wwxYw)
Nc��eZdZd�Zy)�BExpressionTestCase.test_error_getattr_undefined.<locals>.Somethingc��yrrMr-s rr zKExpressionTestCase.test_error_getattr_undefined.<locals>.Something.__repr__�r!rNr"rMrrr#r_�r$rr#r%rrrIrr&rJ�%<Something> has no member named "nil"z<Expression 'something.nil'>�'never found the frame I was looking for�r)rr$rLr	rrPr�rMrNrQrRrSrTrU�
rr#rrVrWrXrY�
search_stringrZr%s
          r�test_error_getattr_undefinedz/ExpressionTestCase.test_error_getattr_undefined�s��	%��	%��/�L��!)�+��	2��M�M�;�	��4�5��I�I�/�0���
	2����D�c�!�f�M�14����.�H�i��:�M�!�)�)�E��-�-��
�
���~�~�,�,���<�<�=�0��	�-�-��	�	�C�D����\�4�+;�+;�<����R����1�1��
	2���)A
�
	D2�BD-�A	D-�-D2c�j�Gd�dt�}tdddd��}	|jd|�i�|jd	�y#t$r�}|jd
t
|��tj�\}}}d}|j}|jr?|j}|jj}	|	j|k(rn|jr�?|jd�|jd	j�|jd|j�Yd}~yd}~wwxYw)
Nc��eZdZd�Zy)�IExpressionTestCase.test_error_getitem_undefined_string.<locals>.Somethingc��yrrMr-s rr zRExpressionTestCase.test_error_getitem_undefined_string.<locals>.Something.__repr__�r!rNr"rMrrr#rj�r$rr#r@rrrIrr&rJraz<Expression 'something["nil"]'>rbrcrds
          r�#test_error_getitem_undefined_stringz6ExpressionTestCase.test_error_getitem_undefined_string�s��	%��	%��,�|�B�!)�+��	2��M�M�;�	��4�5��I�I�/�0���
	2����D�c�!�f�M�14����.�H�i��A�M�!�)�)�E��-�-��
�
���~�~�,�,���<�<�=�0��	�-�-��	�	�C�D����\�4�+;�+;�<����R����1�1��
	2�rgc�t�tddi��}|jdtd�j|��y)N�some�thing)�dictzdict['some']�rprrr$r�s  r�!test_getitem_with_constant_stringz4ExpressionTestCase.test_getitem_with_constant_string�s1���&�'�*�+������*�^�"<�"E�"E�d�"K�Lrc���tdddddd���}|jdtd�j|��|jdtd	�j|��|jdtd
�j|��|jdtd�j|��|jdtd�j|��y)
Nr*�baz�quox�quooox�foobar)Tg@Nr9sfoo��valueszvalues[True]zvalues[2.5]z
values[42]zvalues[b"foo"]zvalues[None]rqr�s  r�test_getitem_with_simple_indexz1ExpressionTestCase.test_getitem_with_simple_indexs���������
���	
����
�>� :� C� C�D� I�J�����
�=� 9� B� B�4� H�I�����:�l�#;�#D�#D�T�#J�K�����:�.>�#?�#H�#H��#N�O������N�!;�!D�!D�T�!J�Krc���tgd���}|jdtd�j|��|jdtd�j|��y)NrH)r�rIzitems[0]rJz	items[-1]rqr�s  r�test_array_indicesz%ExpressionTestCase.test_array_indicessL���)�$������J�z�2�;�;�D�A�B�����J�{�3�<�<�T�B�Crc�2�Gd�dt�}|�dd�}|jdtd�j|��|jdtd�j|��|jdtd�j|��y)	Nc��eZdZdZy)�CExpressionTestCase.test_item_access_for_attributes.<locals>.MyClass�BarN)rrr�myattrrMrr�MyClassrs���Frr�r�)�minerCr�zmine.myattrzmine["myattr"]z	mine[key])r)rrr$)rr�r�s   r�test_item_access_for_attributesz2ExpressionTestCase.test_item_access_for_attributess{��	�f�	��	�(�3������
�=� 9� B� B�4� H�I�����
�+;� <� E� E�d� K�L�����
�;� 7� @� @�� F�Grc�t�tddi��}|jdtd�j|��y)Nr+r*rxzvalues[str("foo")]rqr�s  r�test_function_in_item_accessz/ExpressionTestCase.test_function_in_item_accesss1���E�5�>�*������
�+?� @� I� I�$� O�PrN)Orrrrrr(r.r0r4r7rArFrKrNrQrTrWrZr^rcrgrirlrnrprrrtrvrxrzr|r~r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r��version_infor�r�r�r�r�r�r�r�r�r�rrr+r;rArGr\rfrlrrrzr|r�r�rMrrrrs���6�
B�
+�H�4�C�
G�@�Q�
J�K�A�B�K�B�L�L�L�L�M�L�M�L�L�L�L�P�
T�
Q�M�N�
L�
P�U�O�P�O�P�M�
H�M�N�L�<�
>�P�(A�
A�
P�(A�
A�
���6�!�	A�
M�&�
/�
)�
J�,�
!�
!�!�
!�*�
*�O�
*�O�7�(2�02�0M�L�D�
H�Qrrc�f�eZdZd�Zd�Zd�Zd�Zd�Zd�Zd�Z	d�Z
d	�Zd
�Ze
sd�Zd�Zd
�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Z d�Z!d�Z"d �Z#d!�Z$d"�Z%d#�Z&d$�Z'd%�Z(d&�Z)d'�Z*d(�Z+d)�Z,e-j\d*k\rd+�Z/d,�Z0d-�Z1d.�Z2d/�Z3d0�Z4d1�Z5d2�Z6d3�Z7d4�Z8d5�Z9y6)7�
SuiteTestCasec�.�td�}t�}tj||d�|j	d�tj
|�}i}|j
|�|jd|d�|j|jk(sJ�y)N�foo = 42rrr9r+)	rrr r!r"r#�executerr%)r�suiter&r'r�s     rr(zSuiteTestCase.test_pickle#sy���j�!���i�����E�3��"�������K�K��$�	������$������T�%�[�)��~�~����+�+�+rc�n�td�}ddi}|j|�|jd|d�y)Nzdata = []
bar = foo
r+r9r*�rr�r�rr�r�s   r�test_internal_shadowingz%SuiteTestCase.test_internal_shadowing.s>�������r�{��
�
�
�d������T�%�[�)rc�j�td�}i}|j|�|jd|d�y)Nr�r9r+r�r�s   r�test_assignzSuiteTestCase.test_assign;s1���j�!����
�
�
�d������T�%�[�)rc��td�}i}|j|�d|vsJ�|jd|d��y)Nzdef donothing(): pass�	donothingr�r�s   r�test_defzSuiteTestCase.test_defAsG���-�.����
�
�
�d���d�"�"�"�����0�t�K�0�2�3rc��td�}ddi}|j|�d|vsJ�|jd|d��y)Nz2
def donothing():
    if True:
        return foo
r+r*r�r�r�s   r�!test_def_with_multiple_statementsz/SuiteTestCase.test_def_with_multiple_statementsHsQ������
�u�~��
�
�
�d���d�"�"�"����� 1��[� 1� 3�4rc�n�td�}i}|j|�|jddg|d�y)Nzl
values = []
def add(value):
    if value not in values:
        values.append(value)
add('foo')
add('bar')
r+r*ryr�r�s   r�test_def_using_nonlocalz%SuiteTestCase.test_def_using_nonlocalSs<��������
�
�
�d�����%����h��8rc��td�}i}|j|�|jd|d�|jd|d�y)NzY
def difference(v1, v2=10):
    return v1 - v2
x = difference(20, 19)
y = difference(20)
rIrP�
r]r�r�s   r�test_def_some_defaultsz$SuiteTestCase.test_def_some_defaults`sL��������
�
�
�d������D��I�&�����T�#�Y�'rc��td�}i}|j|�|jd|d�|jd|d�|jd|d�y)Nzn
def difference(v1=100, v2=10):
    return v1 - v2
x = difference(20, 19)
y = difference(20)
z = difference()
rIrPr�r]�Z�zr�r�s   r�test_def_all_defaultsz#SuiteTestCase.test_def_all_defaultsls`��������
�
�
�d������D��I�&�����T�#�Y�'�����T�#�Y�'rc�j�td�}i}|j|�|jd|d�y)Nzj
def mysum(*others):
    rv = 0
    for n in others:
        rv = rv + n
    return rv
x = mysum(1, 2, 3)
r�rPr�r�s   r�test_def_varargzSuiteTestCase.test_def_varargzs8��������
�
�
�d������D��I�&rc��td�}i}|j|�|jddgt|d��y)Nz^
def smash(**kw):
    return [''.join(i) for i in kw.items()]
x = smash(foo='abc', bar='def')
�bardef�fooabcrP)rr�r�sortedr�s   r�test_def_kwargszSuiteTestCase.test_def_kwargs�sB������
��
�
�
�d�����(�H�-�v�d�3�i�/@�Arc�j�td�}i}|j|�|jd|d�y)Nz8
def kwonly(*args, k):
    return k
x = kwonly(k="foo")
r+rPr�r�s   r�test_def_kwonlyargz SuiteTestCase.test_def_kwonlyarg�s8�����E�
�D��M�M�$�����U�D��I�.rc��td�}i}|j|�|jd|d�|jd|d�y)NzK
def kwonly(*args, k="bar"):
    return k
x = kwonly(k="foo")
y = kwonly()
r+rPr*r]r�r�s   r�test_def_kwonlyarg_with_defaultz-SuiteTestCase.test_def_kwonlyarg_with_default�sL�����E��D��M�M�$�����U�D��I�.����U�D��I�.rc�n�td�}i}|j|�|jddg|d�y)Nz�
def doit():
    values = []
    def add(value):
        if value not in values:
            values.append(value)
    add('foo')
    add('bar')
    return values
x = doit()
r+r*rPr�r�s   r�test_def_nestedzSuiteTestCase.test_def_nested�s<���
�
����
�
�
�d�����%����c��3rc�j�td�}i}|j|�|jd|d�y)Nzl
def lower(fun):
    return lambda: fun().lower()

@lower
def say_hi():
    return 'Hi!'

result = say_hi()
zhi!�resultr�r�s   r�test_def_with_decoratorz%SuiteTestCase.test_def_with_decorator�s8���	�	����
�
�
�d�������X��/rc�L�td�}i}|j|�d|vsJ�y)Nzfoo = 42
del foo
r+�rr�r�s   r�test_deletezSuiteTestCase.test_delete�s2��������
�
�
�d���D� � � rc�L�td�}i}|j|�d|vsJ�y)Nzclass plain(object): pass�plainr�r�s   r�
test_classzSuiteTestCase.test_class�s*���1�2����
�
�
�d���$���rc�|�td�}i}|j|�|jdt|d��y)Nz�
def create():
    class Foobar(object):
        def __str__(self):
            return 'foobar'
    return Foobar()
x = create()
rwrP)rr�rrPr�s   r�test_class_in_defzSuiteTestCase.test_class_in_def�s<��������
�
�
�d������3�t�C�y�>�2rc�L�td�}i}|j|�d|vsJ�y)Nz7class plain(object):
    def donothing():
        pass
r�r�r�s   r�test_class_with_methodsz%SuiteTestCase.test_class_with_methods�s0��������
�
�
�d���$���rc�L�td�}i}|j|�d|vsJ�y)Nzfrom itertools import repeat�repeatr�r�s   r�test_importzSuiteTestCase.test_import�s,���4�5����
�
�
�d���4���rc�\�td�}t�}|j|�d|vsJ�y)Nzfrom itertools import *r�)rrr�r�s   r�test_import_starzSuiteTestCase.test_import_star�s.���/�0���y��
�
�
�d���4���rc��td�}t�}|j|�d|vsJ�|jgd�t	|d���y)NzDdef fun():
    from itertools import repeat
    return repeat(1, 3)
r�)rIrIrI�fun)rrr�rr�r�s   r�test_import_in_defz SuiteTestCase.test_import_in_def�sQ�������y��
�
�
�d���t�#�#�#�����D���e���$7�8rc�n�td�}i}|j|�|jgd�|d�y)Nz-x = []
for i in range(3):
    x.append(i**2)
)rrIrfrPr�r�s   r�test_forzSuiteTestCase.test_fors8��������
�
�
�d������D��I�.rc��td�}i}|j|�d|vsJ�|jd|d��y)NzVdef loop():
    for i in range(10):
        if i == 5:
            break
    return i
�loopr�r�r�s   r�test_for_in_defzSuiteTestCase.test_for_in_def
sH��������
�
�
�d����~��~�����L�D��L�N�+rc�n�td�}ddi}|j|�|jd|d�y)Nzif foo == 42:
    x = True
r+r9TrPr�r�s   r�test_ifzSuiteTestCase.test_ifs<�������r�{��
�
�
�d������t�C�y�)rc�\�td�}|jt|ji�y)Nzraise NotImplementedError)rr9r1r��rr�s  r�
test_raisezSuiteTestCase.test_raises$���5�6�����-�u�}�}�b�Arc�j�td�}i}|j|�|jd|d�y)NzXtry:
    import somemod
except ImportError:
    somemod = None
else:
    somemod.dosth()�somemodr�r�s   r�test_try_exceptzSuiteTestCase.test_try_except"s8��������
�
�
�d������t�I��/rc�j�td�}i}|j|�|jd|d�y)Nz%try:
    x = 2
finally:
    x = None
rPr�r�s   r�test_finallyzSuiteTestCase.test_finally-s8������
��
�
�
�d������t�C�y�)rc�n�td�}ddi}|j|�|jd|d�y)Nz>x = 0
while x < 5:
    x += step
    if x == 4:
        break
�steprrfrPr�r�s   r�test_while_breakzSuiteTestCase.test_while_break7s<��������{��
�
�
�d������D��I�&rc�r�td�}ddi}|jd|i�|jd|d�y)Nzd['k'] += 42�krI�d�+r��rr�r�s   r�#test_augmented_attribute_assignmentz1SuiteTestCase.test_augmented_attribute_assignmentBs9���n�%��
�!�H��
�
�
�s�A�h������Q�s�V�$rc�8�td�ji�y)Nzx = 1; x += 42; assert x == 43r�r-s r�test_local_augmented_assignz)SuiteTestCase.test_local_augmented_assignHs��
�.�/�7�7��;rc�f�i}td�j|�|jd|d�y)Nz6def foo():
    i = 1
    i += 1
    return i
x = foo()rrPr��rr�s  r�test_augmented_assign_in_defz*SuiteTestCase.test_augmented_assign_in_defKs3����
�
�	��g�a�j�����A�c�F�#rc�f�i}td�j|�|jd|d�y)NzQdef foo():
    i = 0
    for n in range(5):
        i += n
    return i
x = foo()r�rPr�r�s  r�$test_augmented_assign_in_loop_in_defz2SuiteTestCase.test_augmented_assign_in_loop_in_defTs3����
�
�	�
�g�a�j�����Q�s�V�$rc�r�td�}ddi}|jd|i�|jd|d�y)Nz)[d['k']] = 'foo',; assert d['k'] == 'foo'r�r*r�r+r�r�s   r�test_assign_in_listz!SuiteTestCase.test_assign_in_list^s:���A�B��
�%�L��
�
�
�s�A�h�������#��'rc�D�td�}|jdddii�y)Nz&x = 1; exec(d['k']); assert x == 42, xr�r�zx = 42r�r�s  r�	test_execzSuiteTestCase.test_execds"���>�?��
�
�
�s�S�(�O�,�-rc�@�td�}|jddi�y)Nz)
def f():
    return v

assert f() == 42
r�r9r�r�s  r�test_returnzSuiteTestCase.test_returnhs#������	�
�
�s�B�i� rc�t�td�}dii}|j|�|jd|dd�y)Nzd['k'] = 'foo'r�r+r�r�r�s   r�test_assign_to_dict_itemz&SuiteTestCase.test_assign_to_dict_itemqs:���&�'���R�y��
�
�
�d�������S�	�#��/rc��Gd�dt�}|�}td�}d|i}|j|�|jd|j�y)Nc��eZdZy)�9SuiteTestCase.test_assign_to_attribute.<locals>.SomethingN)rrrrMrrr#r�xs�rr#zobj.attr = 'foo'rr+)r)rr�r�attr)rr#r&r�r�s     r�test_assign_to_attributez&SuiteTestCase.test_assign_to_attributewsF��%��%��K�	��(�)���y�!��
�
�
�d������	���/rc��Gd�dt�}|�}td�jd|i�|jt	|d��y)Nc��eZdZd�Zy)�-SuiteTestCase.test_delattr.<locals>.Somethingc��d|_y)Nr+)r�r-s rrz6SuiteTestCase.test_delattr.<locals>.Something.__init__�s	��!��	rNrrMrrr#r��s��
"rr#zdel obj.attrrr�)r)rr��assertFalse�hasattr)rr#rs   r�test_delattrzSuiteTestCase.test_delattrsC��	"��	"��k��
�n��%�%�u�c�l�3������f�-�.rc�h�ddi}td�jd|i�|jd|�y)Nr�r+z
del d['k']r�)rr��assertNotInr�s  r�test_delitemzSuiteTestCase.test_delitem�s2��
�%�L��
�l��#�#�S�!�H�-�����a� rc�|�t�\}}tj|d�}	|jd�|j	d�|j�d|i}t
d�}|j|�|jddg|d�tj|�y#tj|�wxYw)	N�wzfoo
bar
r�pathz{from __future__ import with_statement
lines = []
with open(path) as file:
    for line in file:
        lines.append(line)
�foo
zbar
�lines�
r�os�fdopen�writer"�closerr�r�remove�r�fdr�r�r�r�s      r�test_with_statementz!SuiteTestCase.test_with_statement�s����9���D��I�I�b�#���	�
�G�G�L�!�
�F�F�1�I�
�G�G�I����A����E�
�M�M�!�����g�w�/��7��<��I�I�d�O��B�I�I�d�O���A)B$�$B;c�n�i}td�}|j|�|jgd�|d�y)Na
results = []
def counter(maximum):
    i = 0
    while i < maximum:
        val = (yield i)
        if val is not None:
            i = val
        else:
            i += 1
it = counter(5)
results.append(next(it))
results.append(it.send(3))
results.append(next(it))
)rrJrf�resultsr�)rr�r�s   r�test_yield_expressionz#SuiteTestCase.test_yield_expression�s8��������	�
�
�a������A�i�L�1r)rJrJc�|�t�\}}tj|d�}	|jd�|j	d�|j�d|i}t
d�}|j|�|jddg|d�tj|�y#tj|�wxYw)Nr�r�rr�z�from __future__ import with_statement
lines = []
with open(path) as file1, open(path) as file2:
    for line in file1:
        lines.append(line)
    for line in file2:
        lines.append(line)
r�r�rs      r�'test_with_statement_with_multiple_itemsz5SuiteTestCase.test_with_statement_with_multiple_items�s����y�H�B���	�	�"�c�"�A�
 ����� ����q�	����	��T�N�������
�
�a� �� � �'�7�!3�Q�w�Z�@��	�	�$����	�	�$��rc�v�td�}dgd�i}|j|�|jddg|d�y)Nzx = numbers[0:2]r�r�rrIrPr�r�s   rr�zSuiteTestCase.test_slice�s;���(�)���<�(��
�
�
�d�����!�Q���c��+rc�z�td�}gd�ddd�}|j|�|jddg|d�y)Nzx = numbers[start:end]r�rrr�rIrPr�r�s   rr�z"SuiteTestCase.test_slice_with_vars�s=���.�/��'�!�A�>��
�
�
�d�����!�Q���c��+rc�v�td�}dgd�i}|j|�|jgd�|d�y)Nzx = numbers[:]r�r�rPr�r�s   rr�zSuiteTestCase.test_slice_copy�s7���&�'���<�(��
�
�
�d������t�C�y�1rc�x�td�}gd�dd�}|j|�|jgd�|d�y)Nzx = numbers[::stride]r�rr�r�rPr�r�s   rr�zSuiteTestCase.test_slice_stride�s7���-�.��*�a�8��
�
�
�d������D��I�.rc�v�td�}gd�dd�}|j|�|jdg|d�y)Nzx = numbers[-1:]r�rr�rfrPr�r�s   rr�z'SuiteTestCase.test_slice_negative_start�s9���(�)��*�a�8��
�
�
�d�����!��d�3�i�(rc�x�td�}gd�dd�}|j|�|jgd�|d�y)Nzx = numbers[:-1]r�rr�r�rPr�r�s   rr�z%SuiteTestCase.test_slice_negative_end�s7���(�)��*�a�8��
�
�
�d������t�C�y�1rc�r�td�}dgd�i}|j|�|jd|d�y)Nzx = numbers[1]r�r�rIrPr�r�s   rr�z!SuiteTestCase.test_slice_constant�s7���&�'���?�+��
�
�
�d������D��I�&rc�z�d�}td�}gd�|d�}|j|�|jd|d�y)Nc��yr�rMrMrrr�z(SuiteTestCase.test_slice_call.<locals>.f�r�rzx = numbers[f()]r�r�rrPr�)rr�r�r�s    rr�zSuiteTestCase.test_slice_call�s<��	��(�)��*��3��
�
�
�d������D��I�&rc�t�td�}gd�dd�}|j|�|jd|d�y)Nzx = numbers[v]r�rr�rPr�r�s   rr�zSuiteTestCase.test_slice_name�s7���&�'��*��3��
�
�
�d������D��I�&rc��Gd�d�}td�}gd�|�d�}|j|�|jd|d�y)Nc��eZdZd�Zy)�7SuiteTestCase.test_slice_attribute.<locals>.ValueHolderc��d|_yrrr-s rrz@SuiteTestCase.test_slice_attribute.<locals>.ValueHolder.__init__rrNrrMrrrrr	rrzx = numbers[obj.value]r�r
rJrPr�)rrr�r�s    rrz"SuiteTestCase.test_slice_attributesE��	�	��.�/��*�;�=�A��
�
�
�d������D��I�&rN):rrrr(r�r�r�r�r�r�r�r�r�rr�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�rrr�r�r
r�r�r�r�r�r�r�r�r�rrMrrr�r�!s��	,�*�*�4�	5�9�
(�(�'�B��	/�
	/�4� 
0�!��3�� � �9�/�
,�*�B�	0�*�	'�%�<�$�%�(�.�!�0�0�/�!�
�(2�(���6�!�	 �,,�,�2�/�)�2�'�'�'�'rr�c�6�tj�}|jtjt
j��|jtjtd��|jtjtd��|S)N�test)
�unittest�	TestSuite�addTest�doctest�DocTestSuiterr�	makeSuiterr�)r�s rr�r�
se����� �E�	�M�M�'�&�&�z�'<�'<�=�>�	�M�M�(�$�$�%7��@�A�	�M�M�(�$�$�]�F�;�<��Lr�__main__r�)�defaultTest)r!rr r��tempfilerr�genshi.corer�genshi.template.baser�genshi.template.evalrrrr	r
�
genshi.compatrrr
�TestCaserr�r�r�mainrMrr�<module>r-s}���	�
�
����(�+�+�<�<�BQ��*�*�BQ�Ji'�H�%�%�i'�X��z���H�M�M�g�&�r