File tree Expand file tree Collapse file tree 5 files changed +11
-11
lines changed Expand file tree Collapse file tree 5 files changed +11
-11
lines changed Original file line number Diff line number Diff line change 1212from instant_python .shared .supported_managers import SupportedManagers
1313from instant_python .shared .supported_python_versions import SupportedPythonVersions
1414from instant_python .shared .supported_templates import SupportedTemplates
15- from test .initialize .utils import test_resources_path
15+ from test .initialize .utils import resources_path
1616
1717
1818@pytest .mark .acceptance
@@ -173,6 +173,6 @@ def _create_template_config(
173173
174174 @staticmethod
175175 def _read_base_config () -> dict :
176- resources_path = test_resources_path () / "base_ipy_config.yml"
177- with resources_path .open ("r" ) as file :
176+ base_config_path = resources_path () / "base_ipy_config.yml"
177+ with base_config_path .open ("r" ) as file :
178178 return yaml .safe_load (file )
Original file line number Diff line number Diff line change 55
66from instant_python .configuration .parser .configuration_file_not_found import ConfigurationFileNotFound
77from instant_python .initialize .infra .persistence .config_repository import YamlConfigRepository
8- from test .initialize .utils import test_resources_path
8+ from test .initialize .utils import resources_path
99
1010
1111class TestConfigurationRepository :
1212 def test_should_read_existing_config_file (self ) -> None :
1313 repository = YamlConfigRepository ()
14- config_path = str (test_resources_path () / "base_ipy_config.yml" )
14+ config_path = str (resources_path () / "base_ipy_config.yml" )
1515
1616 raw_config = repository .read (config_path )
1717
Original file line number Diff line number Diff line change 22from jinja2 import TemplateNotFound
33
44from instant_python .initialize .infra .renderer .jinja_environment import JinjaEnvironment
5- from test .initialize .utils import test_resources_path
5+ from test .initialize .utils import resources_path
66
77
88class TestJinjaEnvironment :
99 def setup_method (self ) -> None :
10- self ._jinja_environment = JinjaEnvironment (user_template_path = str (test_resources_path ()))
10+ self ._jinja_environment = JinjaEnvironment (user_template_path = str (resources_path ()))
1111
1212 def test_should_initialize_environment (self ) -> None :
1313 expect (self ._jinja_environment ._env ).not_to (be_none )
Original file line number Diff line number Diff line change 55from instant_python .project_creator .node import NodeType
66from instant_python .shared .supported_templates import SupportedTemplates
77from test .config .domain .mothers .config_schema_mother import ConfigSchemaMother
8- from test .initialize .utils import test_resources_path
8+ from test .initialize .utils import resources_path
99
1010
1111class TestJinjaProjectRenderer :
1212 def test_should_render_standard_project_structure (self ) -> None :
1313 config = ConfigSchemaMother .with_template (
1414 template = SupportedTemplates .STANDARD .value
1515 )
16- renderer = JinjaProjectRenderer (env = JinjaEnvironment (str (test_resources_path ())))
16+ renderer = JinjaProjectRenderer (env = JinjaEnvironment (str (resources_path ())))
1717
1818 project_structure = renderer .render (context_config = config )
1919
@@ -24,7 +24,7 @@ def test_should_include_file_template_content_in_project_structure(self) -> None
2424 config = ConfigSchemaMother .with_template (
2525 template = SupportedTemplates .STANDARD .value
2626 )
27- renderer = JinjaProjectRenderer (env = JinjaEnvironment (str (test_resources_path ())))
27+ renderer = JinjaProjectRenderer (env = JinjaEnvironment (str (resources_path ())))
2828
2929 project_structure = renderer .render (context_config = config )
3030
Original file line number Diff line number Diff line change 11from pathlib import Path
22
33
4- def test_resources_path () -> Path :
4+ def resources_path () -> Path :
55 return Path ("test" ).resolve () / "resources"
You can’t perform that action at this time.
0 commit comments