11
11
from pytask_environment .database import Environment
12
12
13
13
14
- @pytest .mark .end_to_end
14
+ @pytest .mark .end_to_end ()
15
15
def test_existence_of_python_executable_in_db (tmp_path , runner ):
16
16
"""Test that the Python executable is stored in the database."""
17
17
task_path = tmp_path .joinpath ("task_dummy.py" )
@@ -33,13 +33,13 @@ def test_existence_of_python_executable_in_db(tmp_path, runner):
33
33
orm .delete (e for e in entity )
34
34
35
35
36
- @pytest .mark .end_to_end
36
+ @pytest .mark .end_to_end ()
37
37
@pytest .mark .parametrize (
38
- "config_file, content" ,
38
+ ( "config_file" , " content") ,
39
39
[("pytask.ini" , "[pytask]" ), ("pyproject.toml" , "[tool.pytask.ini_options]" )],
40
40
)
41
41
def test_flow_when_python_version_has_changed (
42
- monkeypatch , tmp_path , runner , config_file , content
42
+ monkeypatch , tmp_path , runner , config_file , content ,
43
43
):
44
44
"""Test the whole use-case.
45
45
@@ -97,17 +97,17 @@ def test_flow_when_python_version_has_changed(
97
97
orm .delete (e for e in entity )
98
98
99
99
100
- @pytest .mark .end_to_end
100
+ @pytest .mark .end_to_end ()
101
101
@pytest .mark .parametrize (
102
- "config_file, content" ,
102
+ ( "config_file" , " content") ,
103
103
[
104
104
("pytask.ini" , "[pytask]\n check_python_version = {}" ),
105
105
("pyproject.toml" , "[tool.pytask.ini_options]\n check_python_version = {}" ),
106
106
],
107
107
)
108
108
@pytest .mark .parametrize ("check_python_version, expected" , [("true" , 1 ), ("false" , 0 )])
109
109
def test_python_version_changed (
110
- monkeypatch , tmp_path , runner , config_file , content , check_python_version , expected
110
+ monkeypatch , tmp_path , runner , config_file , content , check_python_version , expected ,
111
111
):
112
112
fake_version = (
113
113
"2.7.8 | packaged by conda-forge | (default, Jul 31 2020, 01:53:57) "
@@ -135,17 +135,17 @@ def test_python_version_changed(
135
135
orm .delete (e for e in entity )
136
136
137
137
138
- @pytest .mark .end_to_end
138
+ @pytest .mark .end_to_end ()
139
139
@pytest .mark .parametrize (
140
- "config_file, content" ,
140
+ ( "config_file" , " content") ,
141
141
[
142
142
("pytask.ini" , "[pytask]\n check_environment = {}" ),
143
143
("pyproject.toml" , "[tool.pytask.ini_options]\n check_environment = {}" ),
144
144
],
145
145
)
146
146
@pytest .mark .parametrize ("check_python_version, expected" , [("true" , 1 ), ("false" , 0 )])
147
147
def test_environment_changed (
148
- monkeypatch , tmp_path , runner , config_file , content , check_python_version , expected
148
+ monkeypatch , tmp_path , runner , config_file , content , check_python_version , expected ,
149
149
):
150
150
tmp_path .joinpath (config_file ).write_text (content .format (check_python_version ))
151
151
source = "def task_dummy(): pass"
0 commit comments