A fix in test configuration. Pushed as one-liner to master: 4e99663379b333e2dd851f06a786c705c3e07e4b

I've opened https://fedorahosted.org/freeipa/ticket/4769 to fix this a better way; either in upstream pytest (if they deem projects with multiple setup.py files as important enough), or in our own plugin.

From 6e5114f7def1cd60e8d6511cf5129b21552bbfc0 Mon Sep 17 00:00:00 2001
From: Petr Viktorin <pvikt...@redhat.com>
Date: Wed, 26 Nov 2014 06:13:34 +0100
Subject: [PATCH] Ignore ipap11helper/setup.py in doctests

Pytest imports all modules when running doctests.
The setup.py runs code on import, and raises an exception,
depending on globa connand-line arguments, so it needs to be ignored.

Also, pytest dislikes multiple top-level modules with the same name
("setup" in this case). Again ignoring is the way to go.
 ipatests/pytest.ini | 1 +
 1 file changed, 1 insertion(+)

diff --git a/ipatests/pytest.ini b/ipatests/pytest.ini
index 3531482d266758b2c31b9775994b16b92bc23bcf..275593682673f25baf75a64ffd90ef84a80d3c4d 100644
--- a/ipatests/pytest.ini
+++ b/ipatests/pytest.ini
@@ -23,3 +23,4 @@ addopts = --doctest-modules
+          --ignore=ipapython/ipap11helper/setup.py

Freeipa-devel mailing list

Reply via email to