3
­?d]n  ã               @   s¦   d dl mZmZmZ yd dlZejjdƒZW n ek
r@   Y nX d dl	Z
d dlZ	d dlmZmZ dd„ Zdd„ Zd	d
„ Zdd„ Zdd„ Zdd„ Zdd„ Zdd„ ZdS )é    )ÚdivisionÚabsolute_importÚprint_functionNz;ignore:the matrix subclass is not:PendingDeprecationWarning)Úassert_array_equalÚassert_c              C   s,   t jjdƒ} tt| tjƒƒ t| jdƒ d S )Né   é   )r   )r   r   )ÚnumpyÚmatlibÚemptyr   Ú
isinstanceÚnpÚmatrixÚshape)Úx© r   ú8/tmp/pip-build-op5p2y5_/numpy/numpy/tests/test_matlib.pyÚ
test_empty   s    r   c               C   sJ   t tjjdƒtjdddgdddggƒƒ t tjjdƒtjddggƒƒ d S )Nr   é   g      ð?)r   r   )r   r	   r
   Zonesr   r   r   r   r   r   Ú	test_ones   s    r   c               C   sJ   t tjjdƒtjdddgdddggƒƒ t tjjdƒtjddggƒƒ d S )Nr   r   g        )r   r   )r   r	   r
   Úzerosr   r   r   r   r   r   Ú
test_zeros   s    r   c              C   s0   t jjdtd�} t| tjddgddggƒƒ d S )Nr   )Údtyper   r   )r	   r
   ÚidentityÚintr   r   r   )r   r   r   r   Útest_identity"   s    r   c           	   C   s´   t jjddtd�} t| tjdddgdddgdddggƒƒ | jjsFt	‚| jj
 sTt	‚t jjddtdd�}t|tjddddgddddgddddggƒƒ |jj s¤t	‚|jj
s°t	‚d S )Nr   r   )Úkr   r   é   ÚF)r   Úorder)r	   r
   Zeyer   r   r   r   ÚflagsÚc_contiguousÚAssertionErrorÚf_contiguous)ZxcZxfr   r   r   Útest_eye&   s    
r$   c              C   s   t jjdƒ} t| jdkƒ d S )Nr   r   )r	   r
   Zrandr   Úndim)r   r   r   r   Ú	test_rand5   s    r&   c              C   s   t jjdƒ} t| jdkƒ d S )Nr   r   )r   r
   Zrandnr   r%   )r   r   r   r   Ú
test_randn:   s    r'   c           
   C   sV   t jdƒ} tjj| ddƒ}t jddddddddgddddddddggƒ}t||ƒ d S )Nr   r   r   r   r   )r   Zaranger	   r
   ZrepmatÚarrayr   )Za1r   Úyr   r   r   Útest_repmat?   s
    
r*   )Ú
__future__r   r   r   ZpytestÚmarkÚfilterwarningsZ
pytestmarkÚImportErrorr	   r   Znumpy.matlibZnumpy.testingr   r   r   r   r   r   r$   r&   r'   r*   r   r   r   r   Ú<module>   s"   
