fix(sonarr): Pass the series ID alongside all GetSeriesHistory events when publishing to the networking channel

This commit is contained in:
2024-12-18 00:39:50 -07:00
parent bafaf7ca7a
commit ec8d748991
6 changed files with 21 additions and 125 deletions
+5 -1
View File
@@ -42,6 +42,10 @@ mod tests {
#[tokio::test]
async fn test_dispatch_by_series_history_block() {
let (mut app, mut sync_network_rx) = construct_app_unit();
app.data.sonarr_data.series.set_items(vec![Series {
id: 1,
..Series::default()
}]);
app
.dispatch_by_sonarr_block(&ActiveSonarrBlock::SeriesHistory)
@@ -50,7 +54,7 @@ mod tests {
assert!(app.is_loading);
assert_eq!(
sync_network_rx.recv().await.unwrap(),
SonarrEvent::GetSeriesHistory(None).into()
SonarrEvent::GetSeriesHistory(1).into()
);
assert!(!app.data.sonarr_data.prompt_confirm);
assert_eq!(app.tick_count, 0);