o
    [h                     @   sB   d dl mZ d dlZddlmZ ddlmZ dd Zdd
dZdS )    )absolute_importN   )
assertions   )excc                  C   s   t jdtjd t jdtjd t jdtjd t jdtjdd t jdtd t jdtdd t jdtdd zdd	l} W n
 tyH   Y d	S w t jd
| j	d d	S )z/Set global warning behavior for the test suite.ignore)categoryerrorzEOracle compatibility version .* is known to have a maximum identifier)r   messagez.*StopIterationz.*inspect.getargspecr   Nonce)
warningsfilterwarningssa_excZSAPendingDeprecationWarningZSADeprecationWarning	SAWarningDeprecationWarningpytestImportErrorZPytestDeprecationWarning)r    r   /home/ubuntu/experiments/live_experiments/Pythonexperiments/Otree/venv/lib/python3.10/site-packages/sqlalchemy/testing/warnings.pysetup_filters   s2   
r   Fc                 C   s<   t jtj||d |  W  d   S 1 sw   Y  dS )zzAssert that each of the given warnings are emitted by fn.

    Deprecated.  Please use assertions.expect_warnings().

    )regexN)r   Z_expect_warningsr   r   )fnZwarning_msgsr   r   r   r   assert_warnings3   s
   $r   )F)	
__future__r   r    r   r   r   r   r   r   r   r   r   <module>   s   #