1- use lazycsv:: Csv ;
2- #[ cfg( feature = "alloc" ) ]
3- use lazycsv:: { Cell , CsvIterItem } ;
1+ use lazycsv:: { Cell , Csv , CsvIterItem } ;
42
53macro_rules! assert_csv {
64 ( $csv: expr, Cell ( $buf: expr) ) => {
@@ -61,7 +59,6 @@ fn basic() {
6159 assert_csv ! ( csv, EOF ) ;
6260}
6361
64- #[ cfg( feature = "alloc" ) ]
6562#[ test]
6663fn no_trailing_newline ( ) {
6764 let mut csv = Csv :: new ( b"a,b,c\n 1,2,3\n 4,5,6" ) ;
@@ -109,7 +106,6 @@ fn position() {
109106 assert_csv ! ( csv, position == data. len( ) ) ; // Position at the end
110107}
111108
112- #[ cfg( feature = "alloc" ) ]
113109#[ test]
114110fn into_rows ( ) {
115111 let mut iter = Csv :: new ( b"a,b,c\n 1,2,3\n 4,5,6\n " ) . into_rows ( ) ;
@@ -132,7 +128,6 @@ fn into_rows() {
132128 assert ! ( iter. next( ) . is_none( ) ) ;
133129}
134130
135- #[ cfg( feature = "alloc" ) ]
136131#[ test]
137132fn into_rows_no_trailing_newline ( ) {
138133 let mut iter = Csv :: new ( b"a,b,c\n 1,2,3\n 4,5,6" ) . into_rows ( ) ;
@@ -155,7 +150,6 @@ fn into_rows_no_trailing_newline() {
155150 assert ! ( iter. next( ) . is_none( ) ) ;
156151}
157152
158- #[ cfg( feature = "alloc" ) ]
159153#[ test]
160154fn into_rows_malformed ( ) {
161155 let mut iter = Csv :: new ( b"a,b,c\n 1,2" ) . into_rows ( ) ;
@@ -168,7 +162,6 @@ fn into_rows_malformed() {
168162 assert ! ( iter. next( ) . unwrap( ) . is_err( ) ) ;
169163}
170164
171- #[ cfg( feature = "alloc" ) ]
172165#[ test]
173166fn into_rows_with_range ( ) {
174167 let mut iter = Csv :: new ( b"a,b,c\n 1,2,3\n 4,5,6\n " ) . into_rows_with_range ( ) ;
@@ -194,7 +187,6 @@ fn into_rows_with_range() {
194187 assert ! ( iter. next( ) . is_none( ) ) ;
195188}
196189
197- #[ cfg( feature = "alloc" ) ]
198190#[ test]
199191fn into_rows_with_range_no_trailing_newline ( ) {
200192 let mut iter = Csv :: new ( b"a,b,c\n 1,2,3\n 4,5,6" ) . into_rows_with_range ( ) ;
0 commit comments