Compare commits
2 Commits
travis-tes
...
test-refac
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
bb05c0d9de | ||
|
|
7c30dd7433 |
@@ -1,4 +1,6 @@
|
||||
include LICENSE.txt
|
||||
include README.rst
|
||||
recursive-include certbot_nginx/tests/testdata *
|
||||
recursive-include tests *
|
||||
recursive-include certbot_nginx/_internal/tls_configs *.conf
|
||||
global-exclude __pycache__
|
||||
global-exclude *.py[cod]
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
"""Certbot Nginx Tests"""
|
||||
@@ -16,7 +16,8 @@ from certbot_nginx._internal import obj
|
||||
from certbot_nginx._internal import parser
|
||||
from certbot_nginx._internal.configurator import _redirect_block_for_domain
|
||||
from certbot_nginx._internal.nginxparser import UnspacedList
|
||||
from certbot_nginx.tests import util
|
||||
|
||||
import test_util as util
|
||||
|
||||
|
||||
class NginxConfiguratorTest(util.NginxTest):
|
||||
@@ -8,7 +8,8 @@ from certbot.tests import util as certbot_util
|
||||
from certbot_nginx._internal import parser
|
||||
|
||||
from certbot_nginx._internal.display_ops import select_vhost_multiple
|
||||
from certbot_nginx.tests import util
|
||||
|
||||
import test_util as util
|
||||
|
||||
|
||||
class SelectVhostMultiTest(util.NginxTest):
|
||||
@@ -13,7 +13,8 @@ from certbot.tests import acme_util
|
||||
from certbot.tests import util as test_util
|
||||
|
||||
from certbot_nginx._internal.obj import Addr
|
||||
from certbot_nginx.tests import util
|
||||
|
||||
import test_util as util
|
||||
|
||||
AUTH_KEY = jose.JWKRSA.load(test_util.load_vector("rsa512_key.pem"))
|
||||
|
||||
@@ -8,7 +8,8 @@ from pyparsing import ParseException
|
||||
|
||||
from certbot_nginx._internal.nginxparser import (
|
||||
RawNginxParser, loads, load, dumps, dump, UnspacedList)
|
||||
from certbot_nginx.tests import util
|
||||
|
||||
import test_util as util
|
||||
|
||||
|
||||
FIRST = operator.itemgetter(0)
|
||||
@@ -12,7 +12,8 @@ from certbot.compat import os
|
||||
from certbot_nginx._internal import nginxparser
|
||||
from certbot_nginx._internal import obj
|
||||
from certbot_nginx._internal import parser
|
||||
from certbot_nginx.tests import util
|
||||
|
||||
import test_util as util
|
||||
|
||||
|
||||
class NginxParserTest(util.NginxTest):
|
||||
@@ -26,7 +26,7 @@ class NginxTest(test_util.ConfigTestCase):
|
||||
self.config = None
|
||||
|
||||
self.temp_dir, self.config_dir, self.work_dir = common.dir_setup(
|
||||
"etc_nginx", "certbot_nginx.tests")
|
||||
"etc_nginx", __name__)
|
||||
self.logs_dir = tempfile.mkdtemp('logs')
|
||||
|
||||
self.config_path = os.path.join(self.temp_dir, "etc_nginx")
|
||||
@@ -85,7 +85,7 @@ class NginxTest(test_util.ConfigTestCase):
|
||||
def get_data_filename(filename):
|
||||
"""Gets the filename of a test data file."""
|
||||
return pkg_resources.resource_filename(
|
||||
"certbot_nginx.tests", os.path.join(
|
||||
__name__, os.path.join(
|
||||
"testdata", "etc_nginx", filename))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user