summaryrefslogtreecommitdiff
path: root/tests/unittests/test_templating.py
diff options
context:
space:
mode:
authorBarry Warsaw <barry@python.org>2015-01-21 15:28:32 -0500
committerBarry Warsaw <barry@python.org>2015-01-21 15:28:32 -0500
commit463d626ba53e54160f350d84831e1877b24f4024 (patch)
treee13078db48bf17c062ced1ce1feed78ddd3a9da0 /tests/unittests/test_templating.py
parentee4a174e2e3b3268ef95485b99d81edea1ca3458 (diff)
downloadvyos-cloud-init-463d626ba53e54160f350d84831e1877b24f4024.tar.gz
vyos-cloud-init-463d626ba53e54160f350d84831e1877b24f4024.zip
Only install cheetah (and only run the cheetah templating test) when in Python
2. Cheetah is not compatible with Python 3.
Diffstat (limited to 'tests/unittests/test_templating.py')
-rw-r--r--tests/unittests/test_templating.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/unittests/test_templating.py b/tests/unittests/test_templating.py
index 3ba4ed8a..957467f6 100644
--- a/tests/unittests/test_templating.py
+++ b/tests/unittests/test_templating.py
@@ -16,6 +16,9 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
+import six
+import unittest
+
from . import helpers as test_helpers
import textwrap
@@ -38,6 +41,7 @@ class TestTemplates(test_helpers.TestCase):
out_data = templater.basic_render(in_data, {'b': 2})
self.assertEqual(expected_data.strip(), out_data)
+ @unittest.skipIf(six.PY3, 'Cheetah is not compatible with Python 3')
def test_detection(self):
blob = "## template:cheetah"