o
    b,	                     @   s   d dl Z d dlmZ d dlZd dlmZmZ d dlmZ d dl	m
Z
 ejdd Zdd Zejd	d
 Zejdd Zejddd ZdS )    N)exists)
initializeimports)PyLinterc                  c   s    d} | V  t |  d S )Nzdependencies_graph.dotosremove)dest r
   \/var/www/secure340b-portal/env/lib/python3.10/site-packages/pylint/test/test_import_graph.pyr	      s   r	   c                 C   s^   t | ddgdgd t| }|  d ksJ W d    d S 1 s(w   Y  d S )NhohoZyep)Zlabasr   z
digraph "dependencies_graph" {
rankdir=LR
charset="utf-8"
URL="." node[shape="box"]
"hoho" [];
"yep" [];
"labas" [];
"yep" -> "hoho" [];
"hoho" -> "labas" [];
"yep" -> "labas" [];
}
)r   Z_dependencies_graphopenreadstrip)r	   streamr
   r
   r   test_dependencies_graph   s   

"r   c                  C   s   t t d} t|  | S )N)reporter)r   	testutilsZTestReporterr   )lr
   r
   r   linter3   s   r   c                  c   s.    d V  dD ]} zt |  W q   Y qd S )N)
import.dotext_import.dotint_import.dotr   )fnamer
   r
   r   remove_files:   s   r   c                 C   s   | }| dd | dd | dd | dd | d	d
 | dd | dd | dd |d |  tdsAJ td
sGJ tdsMJ d S )N
persistentFZreportsTenabler   zimport-graphr   zext-import-graphr   zint-import-graphr   ignore)zfunc_unknown_encoding.pyinput)Zglobal_set_optioncheckZgenerate_reportsr   )r   r   r
   r
   r   test_checker_dep_graphsD   s   
r    )r   os.pathr   ZpytestZpylint.checkersr   r   Zpylint.lintr   Zpylint.testutilsr   Zfixturer	   r   r   r   markZusefixturesr    r
   r
   r
   r   <module>   s   



	