o
    Ni                     @   sn   d Z ddlmZ ddlmZ ddlmZ ddlmZ ddlm	Z	 G dd dej
jZed	kr5ej
  dS dS )
zwordnet dataset.    )absolute_import)division)print_functionN)wordnetc                       sD   e Zd ZdZejZddddZdddZ fdd	Z	d
d Z
  ZS )WordnetTestzTests for Wordnet dataset.         )train
validationtest )WN18WN18RRc                    s"   t t|   | | jjj dS )z&Before download, there is no metadata.N)superr   	test_infoassertEmptybuilderinfometadata)self	__class__ Y/home/ubuntu/.local/lib/python3.10/site-packages/tensorflow_datasets/text/wordnet_test.pyr   (   s   zWordnetTest.test_infoc              	   C   s   | j jD ]?}| |j/ | j|d}| | | |jjd d d d | |jjd d d d W d	   n1 s>w   Y  qd	S )
z0After downloading, metadata should be populated.)configsynsets07491708name__enjoyment_NN_108769179
definitionzOan area in Germany around the upper Elbe river; the original home of the SaxonsN)	r   BUILDER_CONFIGS_subTestr   _make_builder _download_and_prepare_as_datasetassertEqualr   r   )r   r   r   r   r   r   $test_info_after_download_and_prepare-   s   
z0WordnetTest.test_info_after_download_and_prepare)__name__
__module____qualname____doc__r   WordnetDATASET_CLASSSPLITSDL_EXTRACT_RESULTr   r'   __classcell__r   r   r   r   r      s    r   __main__)r+   
__future__r   r   r   tensorflow_datasets.public_api
public_apitfdstensorflow_datasets.textr   testingDatasetBuilderTestCaser   r(   	test_mainr   r   r   r   <module>   s   !