File tree Expand file tree Collapse file tree 1 file changed +21
-1
lines changed
jobs/gtfs-schedule-validator Expand file tree Collapse file tree 1 file changed +21
-1
lines changed Original file line number Diff line number Diff line change 11from pathlib import Path
22
3+ import pytest
34import toml
4- from gtfs_schedule_validator_hourly import __version__
5+ from gtfs_schedule_validator_hourly import __version__ , app
6+ from typer .testing import CliRunner
57
68
79def test_version ():
@@ -20,3 +22,21 @@ def test_versions_are_in_sync():
2022 package_init_version = __version__
2123
2224 assert package_init_version == pyproject_version
25+
26+
27+ class TestGtfsScheduleValidator :
28+ @pytest .fixture
29+ def runner (self ) -> CliRunner :
30+ return CliRunner ()
31+
32+ def test_no_extracts (self , runner ):
33+ hour_start = "2020-02-20T20:00"
34+ result = runner .invoke (
35+ app ,
36+ [
37+ "validate-hour" ,
38+ hour_start ,
39+ ],
40+ )
41+ assert result .exit_code == 0
42+ assert "found 0 extracts to process, exiting" in result .stdout
You can’t perform that action at this time.
0 commit comments