← Back
Editing: errors_test.cpython-38.pyc
U �]7 � @ sp d Z ddlZddlZddlmZ ddlmZ ddlmZ G dd� dej �Z G dd � d ej �Zed krle� � dS )zTests for certbot.errors.� N)�messages)�achallenges)� acme_utilc @ s( e Zd ZdZdd� Zdd� Zdd� ZdS ) �FailedChallengesTestz*Tests for certbot.errors.FailedChallenges.c C sB ddl m} |ttjdtjtjd tj ddd�d�d�g��| _ d S ) Nr ��FailedChallenges�example.com�tls�detail��typr �ZchallZuri�error�ZdomainZchallb)�certbot.errorsr �setr �DNSr � ChallengeBodyr �DNS01�Errorr )�selfr � r �;/usr/lib/python3/dist-packages/certbot/tests/errors_test.py�setUp s ��zFailedChallengesTest.setUpc C s | � t| j��d�� d S )N�9Failed authorization procedure. example.com (dns-01): tls�� assertTrue�strr � startswith�r r r r �test_str s �zFailedChallengesTest.test_strc C sX ddl m} d}|ttjdtjtjd tj d|d�d�d�g��}| � t|��d �� d S ) Nr r u عدالةr r r r r r ) r r r r r r r r r r r r r )r r Z arabic_detailZarabic_errorr r r �test_unicode s ���z!FailedChallengesTest.test_unicodeN)�__name__� __module__�__qualname__�__doc__r r r! r r r r r s r c @ s( e Zd ZdZdd� Zdd� Zdd� ZdS ) �StandaloneBindErrorTestz-Tests for certbot.errors.StandaloneBindError.c C s ddl m} |tjjd�| _d S )Nr )�StandaloneBindError�� )r r'