comparison tests/test_included.py @ 259:15ade7ad64da

hopefully introduce a failing test for tox install
author Jeff Hammel <k0scist@gmail.com>
date Sat, 27 May 2017 17:50:13 -0700
parents e21f013586d0
children
comparison
equal deleted inserted replaced
258:e21f013586d0 259:15ade7ad64da
2 tests for templates included in the package 2 tests for templates included in the package
3 """ 3 """
4 4
5 included_templates = set(['python-package']) 5 included_templates = set(['python-package'])
6 6
7 import shutil
7 import tempfile 8 import tempfile
8 from makeitso.makeitso import get_entry_points 9 from makeitso.makeitso import get_entry_points
9 10
10 def test_included_template(): 11 def test_included_template():
11 """ensure we are packaging included template correctly""" 12 """ensure we are packaging included template correctly"""
21 # get the variables 22 # get the variables
22 missing = template.missing() 23 missing = template.missing()
23 variables = {variable: variable 24 variables = {variable: variable
24 for variable in missing} 25 for variable in missing}
25 26
27 # render
28 tmpdir = tempfile.mkdtemp()
29 try:
30 template.substitute(variables, output=tmpdir)
31 finally:
32 shutil.rmtree(tmpdir)