@@ -164,7 +164,7 @@ def test_main_with_bad_thresholds(
164164) -> None :
165165 """Test cli with bad thresholds."""
166166 result = create_typer_cli_runner .invoke (
167- cli .app , [str (sample_data_gt3x ), "-t" , "- 3.0" ]
167+ cli .app , [str (sample_data_gt3x ), "-t" , "3.0" ]
168168 )
169169
170170 assert result .exit_code != 0
@@ -178,10 +178,33 @@ def test_main_with_bad_epoch(
178178) -> None :
179179 """Test cli with invalid epoch length."""
180180 result = create_typer_cli_runner .invoke (
181- cli .app , ( [str (sample_data_gt3x ), "-e" , "-5" ])
181+ cli .app , [str (sample_data_gt3x ), "-e" , "-5" ]
182182 )
183183
184184 assert result .exit_code != 0
185185 # partial matching due to ANSI escape sequences in Github Actions
186186 assert "Invalid value for" in result .output
187187 assert "is not in the range x>=1." in result .output
188+
189+
190+ @pytest .mark .parametrize (
191+ "verbosity, expected_log_level" ,
192+ [
193+ ("-v" , logging .INFO ),
194+ ("-vv" , logging .DEBUG ),
195+ ("-vvv" , logging .DEBUG ),
196+ ],
197+ )
198+ def test_main_verbosity (
199+ mocker : pytest_mock .MockerFixture ,
200+ sample_data_gt3x : pathlib .Path ,
201+ create_typer_cli_runner : CliRunner ,
202+ verbosity : int ,
203+ expected_log_level : int ,
204+ ) -> None :
205+ """Test cli with different verbosity levels."""
206+ mock_run = mocker .patch .object (orchestrator , "run" )
207+
208+ create_typer_cli_runner .invoke (cli .app , [str (sample_data_gt3x ), verbosity ])
209+
210+ assert mock_run .call_args .kwargs ["verbosity" ] == expected_log_level
0 commit comments