o
    i                     @   s,   d Z ddlmZ dd Zdd Zdd Zd	S )
zTest kernel interrupt   )EDITOR_PAGEc                 C   s.   | j dtd | j dtd | jdtd d S )Nz#kernellinkpagez#int_kernelEscape)try_click_selectorr   pressnotebook_frontend r
   d/var/www/edux/Edux_v2/venv/lib/python3.10/site-packages/nbclassic/tests/end_to_end/test_interrupt.pyinterrupt_from_menu   s   r   c                 C   s    | j dtd | jdtd d S )Niir   r   )typer   r   r   r
   r
   r   interrupt_from_keyboard   s   r   c                 C   sb   d}| j d|d ttfD ]!}| d |   | d ||  | d}d| v s.J qdS )zi Test the interrupt function using both the button in the Kernel menu and the keyboard shortcut "ii"
    z/import time
for x in range(3):
   time.sleep(1)    )indexcontentKeyboardInterruptN)	edit_cellr   r   clear_cell_outputto_command_modeexecute_cellwait_for_cell_outputget_inner_text)r	   textinterrupt_methodoutputr
   r
   r   test_interrupt   s   


r   N)__doc__utilsr   r   r   r   r
   r
   r
   r   <module>   s
    