o
    .j                     @   s   d Z ddlZddlZddlZddlZddlZeejZ	e	jjZ
ee
dZdgZejdedd Ze
d Ze
d	 geed
eedeedeedZejdedd Zdd ZdS )a  This file tests the source code provided by the documentation.

See
- doctest documentation: https://docs.python.org/3/library/doctest.html
- Issue 443: https://github.com/collective/icalendar/issues/443

This file should be tests, too:

    >>> print("Hello World!")
    Hello World!

    Nz*.pyrecurring_ical_eventsmodule_namec                 C   s:   t | }tj|| d}|jdksJ |j d|  dS )z,This test runs doctest on the Python module.)namer    errors in N)	importlibimport_moduledoctesttestmodfailed)r   moduletest_result r   a/home/thesage/.local/lib/python3.10/site-packages/recurring_ical_events/test/test_with_doctest.pytest_docstring_of_python_file   s   
"r   docsz
README.rstz*/*.rstz*.rstz*/*.mddocumentc                 C   s:   t jt| d|dd}|jdksJ |j d| j dS )z^This test runs doctest on a documentation file.

    functions are also replaced to work.
    F)module_relativeglobsraise_on_errorr   r   N)r   testfilestrr
   r   )r   env_for_doctestr   r   r   r   test_documentation_file2   s   $r   c                 C   s   dt jv sJ dS )z#Allow importing zoneinfo for tests.zoneinfoN)sysmodules)r   r   r   r   test_can_import_zoneinfoA   s   r   )__doc__r   r   pathlibr   pytestPath__file__parentHEREPROJECT_PATHlistrglobPYTHON_FILESMODULE_NAMESmarkparametrizer   DOCSglobDOCUMENT_PATHSr   r   r   r   r   r   <module>   s6    
	
