Skip to content

Commit

Permalink
FIX: Patch Incoming Data on RPM Tests
Browse files Browse the repository at this point in the history
It looks like our python ci hasn't been running for the last few PRs.
Now that it is, some of the tests around multi-carriage-detail parsing
have started to fail. Fixing those now.

* Incoming files were adjusted to have multi-carriage-detail columns so
  that vehicle positions can be calculated correctly.
* Update column count around vehicle position dataframes since some of
  them will now have the mcd as well.
  • Loading branch information
mzappitello committed Mar 26, 2024
1 parent 88f8679 commit 6ecba3a
Show file tree
Hide file tree
Showing 6 changed files with 1,647 additions and 1,647 deletions.
8 changes: 4 additions & 4 deletions tests/performance_manager/test_performance_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -524,20 +524,20 @@ def test_gtfs_rt_processing(
route_ids = rail_routes_from_filepath(files["vp_paths"], rpm_db_manager)
positions = get_vp_dataframe(files["vp_paths"], route_ids)
position_size = positions.shape[0]
assert positions.shape[1] == 12
assert positions.shape[1] == 13

# check that the types can be set correctly
positions = transform_vp_datatypes(positions)
assert positions.shape[1] == 12
assert positions.shape[1] == 13
assert position_size == positions.shape[0]

# check that it can be combined with the static schedule
positions = add_static_version_key_column(positions, rpm_db_manager)
assert positions.shape[1] == 13
assert positions.shape[1] == 14
assert position_size == positions.shape[0]

positions = add_parent_station_column(positions, rpm_db_manager)
assert positions.shape[1] == 14
assert positions.shape[1] == 15
assert position_size == positions.shape[0]

positions = transform_vp_timestamps(positions)
Expand Down
Binary file not shown.
Binary file not shown.
Loading

0 comments on commit 6ecba3a

Please sign in to comment.