관리-도구
편집 파일: test_deprecations.cpython-38.pyc
U -?�f� � @ sv d dl mZ d dlmZ d dlmZ d dlmZ ddl mZ ddl mZ ddl m Z dd l m Z G d d� dej�ZdS ) � )�fixtures)�eq_)�Column)�Table� )�Integer)�select)�testing)�unionc @ sz e Zd ZdZedd� �Zedd� �Zddd�Zd d � Zdd� Z e jje jj d d� ��Ze jjdd� �Zdd� Zdd� ZdS )�DeprecatedCompoundSelectTestTc C s* t d|tdtdd�tdt�tdt�� d S )N� some_table�idT)Zprimary_key�x�y)r r r )�cls�metadata� r �Z/opt/hc_python/lib64/python3.8/site-packages/sqlalchemy/testing/suite/test_deprecations.py� define_tables s �z*DeprecatedCompoundSelectTest.define_tablesc C s@ |� | jj�� dddd�dddd�dddd�dddd�g� d S )N� r )r r r r � � )�execute�tablesr �insert)r � connectionr r r �insert_data s ��z(DeprecatedCompoundSelectTest.insert_datar c C s t |�||��� |� d S )N)r r Zfetchall)�self�connr �result�paramsr r r �_assert_result, s z+DeprecatedCompoundSelectTest._assert_resultc C st | j j}t|��|jjdk�}t|��|jjdk�}t||�}t�d��" | � ||� |jj�ddg� W 5 Q R X d S �Nr r �AThe SelectBase.c and SelectBase.columns attributes are deprecated�r r r �r r r )r r r �where�cr r r �expect_deprecatedr! �order_by�r r �table�s1�s2�u1r r r �test_plain_union/ s � �z-DeprecatedCompoundSelectTest.test_plain_unionc C s| | j j}t|��|jjdk�}t|��|jjdk�}t||��� �� }t� d��" | � ||�|jj�ddg� W 5 Q R X d S r"