fix(sonarr): Corrected a bug that would cause a crash if a user spams the ESC key while searching for a new series and the search results are still loading
This commit is contained in:
@@ -1714,6 +1714,20 @@ mod tests {
|
||||
});
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_add_series_search_no_panic_on_none_search_result() {
|
||||
let mut app = App::default();
|
||||
app.data.sonarr_data.add_series_search = None;
|
||||
|
||||
AddSeriesHandler::with(
|
||||
DEFAULT_KEYBINDINGS.esc.key,
|
||||
&mut app,
|
||||
ActiveSonarrBlock::AddSeriesSearchResults,
|
||||
None,
|
||||
)
|
||||
.handle();
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_build_add_series_body() {
|
||||
let mut app = App::default();
|
||||
|
||||
Reference in New Issue
Block a user