Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/certbot/certbot.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdrien Ferrand <adferrand@users.noreply.github.com>2019-03-02 00:18:06 +0300
committerohemorange <ebportnoy@gmail.com>2019-03-02 00:18:06 +0300
commit841f8efd0aa7dc2ba249b303e6be664d0a6647e3 (patch)
tree6d1408e31198fb6d743eb6caa8b3a3ee8775fc98 /certbot-ci/certbot_integration_tests/nginx_tests/test_main.py
parentefc8d49806b14a31d88cfc0f1b6daca1dd373d8d (diff)
[Unix] Create a framework for certbot integration tests: PART 1 (#6578)
* First part * Several optimizations about the docker env setup * Documentation * Various corrections and documentation. Add acme and certbot explicitly as dependencies of certbot-ci. * Correct a variable misinterpreted as a pytest hook * Correct strict parsing option on pebble * Refactor acme setup to be executed from pytest hooks. * Pass TRAVIS env variable to trigger specific xdist logic * Retrigger build. * Work in progress * Config operational * Propagate to xdist * Corrections on acme and misc * Correct subnet for pebble * Remove gobetween, as tls-sni challenges are not tested anymore. * Improve pebble setup. Reduce LOC. * Update acme.py * Optimize acme ca setup, with less temporary assets * Silent setup * Clean code * Remove unused workspace * Use default network driver * Remove bridge * Update package documentation * Remove rerun capability for integration tests, not needed. * Add documentation * Variable for all ports and subnets used by the stack * Update certbot-ci/certbot_integration_tests/conftest.py Co-Authored-By: adferrand <adferrand@users.noreply.github.com> * Update certbot-ci/certbot_integration_tests/utils/acme.py Co-Authored-By: adferrand <adferrand@users.noreply.github.com> * Update certbot-ci/certbot_integration_tests/utils/misc.py Co-Authored-By: adferrand <adferrand@users.noreply.github.com> * Update tox.ini Co-Authored-By: adferrand <adferrand@users.noreply.github.com> * Update certbot-ci/certbot_integration_tests/utils/misc.py Co-Authored-By: adferrand <adferrand@users.noreply.github.com> * Update certbot-ci/certbot_integration_tests/utils/acme.py Co-Authored-By: adferrand <adferrand@users.noreply.github.com> * Update certbot-ci/certbot_integration_tests/utils/acme.py Co-Authored-By: adferrand <adferrand@users.noreply.github.com> * Update certbot-ci/certbot_integration_tests/conftest.py Co-Authored-By: adferrand <adferrand@users.noreply.github.com> * Rename to acme_server * Add comment * Refactor in a unique context fixture * Remove the need of CERTBOT_ACME_XDIST environment variable * Remove nonstrict/strict options in pebble * Clean dependencies * Clean tox * Change function name * Add comment about coveragerc specificities * Change a comment. * Update setup.py * Update conftest.py * Use the production-ready docker-compose.yml file for Pebble * New style class * Tune pebble to have a stable test environment * Pin a dependency
Diffstat (limited to 'certbot-ci/certbot_integration_tests/nginx_tests/test_main.py')
-rw-r--r--certbot-ci/certbot_integration_tests/nginx_tests/test_main.py17
1 files changed, 17 insertions, 0 deletions
diff --git a/certbot-ci/certbot_integration_tests/nginx_tests/test_main.py b/certbot-ci/certbot_integration_tests/nginx_tests/test_main.py
new file mode 100644
index 000000000..472e5e7b7
--- /dev/null
+++ b/certbot-ci/certbot_integration_tests/nginx_tests/test_main.py
@@ -0,0 +1,17 @@
+import pytest
+
+from certbot_integration_tests.nginx_tests import context as nginx_context
+
+
+@pytest.fixture()
+def context(request):
+ # Fixture request is a built-in pytest fixture describing current test request.
+ integration_test_context = nginx_context.IntegrationTestsContext(request)
+ try:
+ yield integration_test_context
+ finally:
+ integration_test_context.cleanup()
+
+
+def test_hello(context):
+ print(context.directory_url)