@@ -71,13 +71,16 @@ def gen_project(**cc_args):
7171 return gen_project
7272
7373
74+ DEMO_PROJ_SLUG = "fair_python_cookiecutter_demo"
75+
76+
7477def test_cookiecutter (gen ):
7578 # generate with default values
7679 dir = gen ()
7780 sanity_check_project (dir )
7881 # should NOT have the code files
79- assert not (dir / "src/my_amazing_app/ api.py" ).is_file ()
80- assert not (dir / "src/my_amazing_app /cli.py" ).is_file ()
82+ assert not (dir / f "src/{ DEMO_PROJ_SLUG } api.py" ).is_file ()
83+ assert not (dir / f "src/{ DEMO_PROJ_SLUG } /cli.py" ).is_file ()
8184 assert not (dir / "tests/test_api.py" ).is_file ()
8285 assert not (dir / "tests/test_cli.py" ).is_file ()
8386 # and the expected license (MIT)
@@ -89,8 +92,8 @@ def test_cookiecutter(gen):
8992 dir = gen (config_file = "./tests/demo.yaml" )
9093 sanity_check_project (dir )
9194 # should have the code files
92- assert (dir / "src/my_amazing_app /api.py" ).is_file ()
93- assert (dir / "src/my_amazing_app /cli.py" ).is_file ()
95+ assert (dir / f "src/{ DEMO_PROJ_SLUG } /api.py" ).is_file ()
96+ assert (dir / f "src/{ DEMO_PROJ_SLUG } /cli.py" ).is_file ()
9497 assert (dir / "tests/test_api.py" ).is_file ()
9598 assert (dir / "tests/test_cli.py" ).is_file ()
9699 # and the expected license (Unlicense)
0 commit comments