Debian Codegraph @

debian/patches/Disable-tests-that-require-network.patch

raw symbols SCIP
1 From: Manuel Traut <[email protected]>
2 Date: Wed, 20 Nov 2024 19:19:03 +0100
3 Subject: Disable tests that require network
4
5 ---
6 podcasts-data/src/dbqueries.rs | 2 ++
7 podcasts-data/src/models/source.rs | 3 +++
8 podcasts-data/src/pipeline.rs | 3 +++
9 podcasts-gtk/src/utils.rs | 3 +++
10 4 files changed, 11 insertions(+)
11
12 diff --git a/podcasts-data/src/dbqueries.rs b/podcasts-data/src/dbqueries.rs
13 index 70dede9..a05e0bc 100644
14 --- a/podcasts-data/src/dbqueries.rs
15 +++ b/podcasts-data/src/dbqueries.rs
16 @@ -548,6 +548,7 @@ mod tests {
17 use crate::utils::get_feed;
18 use anyhow::Result;
19
20 + /* Disable tests that need network connection
21 #[test]
22 fn test_update_none_to_played_now() -> Result<()> {
23 truncate_db()?;
24 @@ -568,6 +569,7 @@ mod tests {
25 assert_eq!(eps_num2, 0);
26 Ok(())
27 }
28 + */
29
30 #[test]
31 fn test_episode_exists() -> Result<()> {
32 diff --git a/podcasts-data/src/models/source.rs b/podcasts-data/src/models/source.rs
33 index 2d1d20c..09c3a9c 100644
34 --- a/podcasts-data/src/models/source.rs
35 +++ b/podcasts-data/src/models/source.rs
36 @@ -318,6 +318,8 @@ mod tests {
37 use crate::downloader::client_builder;
38 use crate::utils::get_feed;
39
40 + /* Disable tests that need a network connection
41 +
42 #[test]
43 fn test_into_feed() -> Result<()> {
44 truncate_db()?;
45 @@ -363,4 +365,5 @@ mod tests {
46 );
47 Ok(())
48 }
49 + */
50 }
51 diff --git a/podcasts-data/src/pipeline.rs b/podcasts-data/src/pipeline.rs
52 index 09b33e2..2993004 100644
53 --- a/podcasts-data/src/pipeline.rs
54 +++ b/podcasts-data/src/pipeline.rs
55 @@ -79,6 +79,8 @@ mod tests {
56 com/feed/podcast",
57 ];
58
59 + /* Disable tests that need a network connectioa
60 +
61 #[test]
62 /// Insert feeds and update/index them.
63 fn test_pipeline() -> Result<(), DataError> {
64 @@ -107,4 +109,5 @@ mod tests {
65 assert_eq!(dbqueries::get_episodes()?.len(), 354);
66 Ok(())
67 }
68 + */
69 }
70 diff --git a/podcasts-gtk/src/utils.rs b/podcasts-gtk/src/utils.rs
71 index 95c2e9b..69b2d2d 100644
72 --- a/podcasts-gtk/src/utils.rs
73 +++ b/podcasts-gtk/src/utils.rs
74 @@ -468,6 +468,8 @@ pub(crate) async fn on_export_clicked(window: &gtk::ApplicationWindow, sender: &
75 };
76 }
77
78 +/* Disable tests that need a network connection
79 +
80 #[cfg(test)]
81 mod tests {
82 use super::*;
83 @@ -645,3 +647,4 @@ mod tests {
84 Ok(())
85 }
86 }
87 +*/