Skip to content

Commit

Permalink
fixed tests (#1444)
Browse files Browse the repository at this point in the history
  • Loading branch information
Sakapoi authored Aug 30, 2024
1 parent c903936 commit 58fec05
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
4 changes: 2 additions & 2 deletions module/core/collection_tools/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ pub mod exposed
pub use prelude::*;

#[ doc( inline ) ]
#[ cfg( feature = "collection_constructors" ) ]
#[ cfg( any( feature = "use_alloc", all( feature = "collection_constructors", not( feature = "no_std" ) ) ) ) ]
pub use crate::
{
vec as dlist,
Expand All @@ -77,7 +77,7 @@ pub mod exposed
};

#[ doc( inline ) ]
#[ cfg( feature = "collection_into_constructors" ) ]
#[ cfg( any( feature = "use_alloc", all( feature = "collection_into_constructors", not( feature = "no_std" ) ) ) ) ]
pub use crate::
{
into_vec,
Expand Down
4 changes: 2 additions & 2 deletions module/core/collection_tools/tests/inc/deque.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@ fn into_constructor()
exp.push_front( 3 );
assert_eq!( got, exp );

let _got : DequeList< &str > = the_module::deque!( "b" );
let _got : DequeList< &str > = the_module::exposed::deque!( "b" );
let _got = the_module::deque!( "b" );
let _got = the_module::exposed::deque!( "b" );

}

Expand Down
4 changes: 3 additions & 1 deletion module/core/collection_tools/tests/inc/vec.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
use super::*;

#[ test ]
#[ cfg( any( not( feature = "no_std" ), feature = "use_alloc" ) ) ]
fn reexport()
{

Expand All @@ -12,7 +13,8 @@ fn reexport()
let got = vec1.last().unwrap().clone();
assert_eq!( got, 2 );

let mut vec2 : the_module::DynList< i32 > = the_module::DynList::new();
use std::vec::Vec as DynList;
let mut vec2 : DynList< i32 > = DynList::new();
vec2.push( 1 );
vec2.push( 2 );
let got = vec2.first().unwrap().clone();
Expand Down

0 comments on commit 58fec05

Please sign in to comment.