diff --git a/hammond-data/tests/feeds/notes.md b/hammond-data/tests/feeds/notes.md index 1531d23..71d5fce 100644 --- a/hammond-data/tests/feeds/notes.md +++ b/hammond-data/tests/feeds/notes.md @@ -5,25 +5,30 @@ #### Intercepted Web view: https://web.archive.org/web/20180120083840/https://feeds.feedburner.com/InterceptedWithJeremyScahill + Raw file: https://web.archive.org/web/20180120083840if_/https://feeds.feedburner.com/InterceptedWithJeremyScahill #### The TipOff Web view: https://web.archive.org/web/20180120110727/https://rss.acast.com/thetipoff + Raw file: https://web.archive.org/web/20180120110727if_/https://rss.acast.com/thetipoff #### Linux Unplugged Web view: https://web.archive.org/web/20180120110314/https://feeds.feedburner.com/linuxunplugged + Raw file: https://web.archive.org/web/20180120110314if_/https://feeds.feedburner.com/linuxunplugged #### Steal the stars Web view: https://web.archive.org/web/20180120104957/https://rss.art19.com/steal-the-stars + Raw file: https://web.archive.org/web/20180120104957if_/https://rss.art19.com/steal-the-stars #### Greater than Code Web view: https://web.archive.org/web/20180120104741/https://www.greaterthancode.com/feed/podcast + Raw file: https://web.archive.org/web/20180120104741if_/https://www.greaterthancode.com/feed/podcast diff --git a/hammond-downloader/src/downloader.rs b/hammond-downloader/src/downloader.rs index 4a0e90a..a700434 100644 --- a/hammond-downloader/src/downloader.rs +++ b/hammond-downloader/src/downloader.rs @@ -225,7 +225,7 @@ mod tests { // to run it. #[ignore] fn test_cache_image() { - let url = "http://www.newrustacean.com/feed.xml"; + let url = "https://web.archive.org/web/20180120110727if_/https://rss.acast.com/thetipoff"; // Create and index a source let source = Source::from_url(url).unwrap(); // Copy it's id @@ -238,7 +238,7 @@ mod tests { let img_path = cache_image(&pd); let foo_ = format!( - "{}{}/cover.png", + "{}{}/cover.jpeg", HAMMOND_CACHE.to_str().unwrap(), pd.title() ); diff --git a/hammond-gtk/src/manager.rs b/hammond-gtk/src/manager.rs index e310cb1..960d951 100644 --- a/hammond-gtk/src/manager.rs +++ b/hammond-gtk/src/manager.rs @@ -133,7 +133,7 @@ mod tests { // THIS IS NOT A RELIABLE TEST // Just quick sanity check fn test_start_dl() { - let url = "http://www.newrustacean.com/feed.xml"; + let url = "https://web.archive.org/web/20180120110727if_/https://rss.acast.com/thetipoff"; // Create and index a source let source = Source::from_url(url).unwrap(); // Copy it's id @@ -142,9 +142,9 @@ mod tests { // Get the Podcast let pd = dbqueries::get_podcast_from_source_id(sid).unwrap(); + let title = "Coming soon... The Tip Off"; // Get an episode - let episode: Episode = - dbqueries::get_episode_from_pk("e000: Hello, world!", pd.id()).unwrap(); + let episode: Episode = dbqueries::get_episode_from_pk(title, pd.id()).unwrap(); let (sender, _rx) = channel(); @@ -153,9 +153,9 @@ mod tests { assert_eq!(ACTIVE_DOWNLOADS.read().unwrap().len(), 1); // Give it soem time to download the file - thread::sleep(time::Duration::from_secs(40)); + thread::sleep(time::Duration::from_secs(20)); - let final_path = format!("{}/{}.unknown", &download_fold, episode.rowid()); + let final_path = format!("{}/{}.mp3", &download_fold, episode.rowid()); println!("{}", &final_path); assert!(Path::new(&final_path).exists()); } diff --git a/hammond-gtk/src/utils.rs b/hammond-gtk/src/utils.rs index 67f6d49..13437ce 100644 --- a/hammond-gtk/src/utils.rs +++ b/hammond-gtk/src/utils.rs @@ -89,7 +89,7 @@ mod tests { // to run it. #[ignore] fn test_get_pixbuf_from_path() { - let url = "http://www.newrustacean.com/feed.xml"; + let url = "https://web.archive.org/web/20180120110727if_/https://rss.acast.com/thetipoff"; // Create and index a source let source = Source::from_url(url).unwrap(); // Copy it's id