File: fix-tests-no-default-features.patch

package info (click to toggle)
rust-ordermap 1.1.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 700 kB
  • sloc: makefile: 2
file content (78 lines) | stat: -rw-r--r-- 2,014 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
Index: ordermap/src/map.rs
===================================================================
--- ordermap.orig/src/map.rs
+++ ordermap/src/map.rs
@@ -20,7 +20,7 @@ pub mod raw_entry_v1;
 #[cfg_attr(docsrs, doc(cfg(feature = "serde")))]
 pub mod serde_seq;
 
-#[cfg(test)]
+#[cfg(all(test, feature = "std"))]
 mod tests;
 
 pub use self::entry::{Entry, IndexedEntry, OccupiedEntry, VacantEntry};
Index: ordermap/src/map/rayon.rs
===================================================================
--- ordermap.orig/src/map/rayon.rs
+++ ordermap/src/map/rayon.rs
@@ -259,7 +259,7 @@ where
     }
 }
 
-#[cfg(test)]
+#[cfg(all(test, feature = "std"))]
 mod tests {
     use super::*;
     use std::vec::Vec;
Index: ordermap/src/map/slice.rs
===================================================================
--- ordermap.orig/src/map/slice.rs
+++ ordermap/src/map/slice.rs
@@ -32,7 +32,7 @@ impl_index!(
     (Bound<usize>, Bound<usize>)
 );
 
-#[cfg(test)]
+#[cfg(all(test, feature = "std"))]
 mod tests {
     use super::*;
     use alloc::vec::Vec;
Index: ordermap/src/set.rs
===================================================================
--- ordermap.orig/src/set.rs
+++ ordermap/src/set.rs
@@ -13,7 +13,7 @@ mod iter;
 mod mutable;
 mod slice;
 
-#[cfg(test)]
+#[cfg(all(test, feature = "std"))]
 mod tests;
 
 pub use self::mutable::MutableValues;
Index: ordermap/src/set/rayon.rs
===================================================================
--- ordermap.orig/src/set/rayon.rs
+++ ordermap/src/set/rayon.rs
@@ -295,7 +295,7 @@ where
     }
 }
 
-#[cfg(test)]
+#[cfg(all(test, feature = "std"))]
 mod tests {
     use super::*;
     use std::vec::Vec;
Index: ordermap/src/set/slice.rs
===================================================================
--- ordermap.orig/src/set/slice.rs
+++ ordermap/src/set/slice.rs
@@ -25,7 +25,7 @@ impl_index!(
     (Bound<usize>, Bound<usize>)
 );
 
-#[cfg(test)]
+#[cfg(all(test, feature = "std"))]
 mod tests {
     use super::*;
     use alloc::vec::Vec;