mirror of
https://github.com/mat007/turtle.git
synced 2026-06-22 12:13:43 +00:00
Added support for movable objects in mock::retrieve
This commit is contained in:
parent
afffdb470a
commit
f872785e26
3 changed files with 18 additions and 0 deletions
|
|
@ -219,6 +219,16 @@ BOOST_AUTO_TEST_CASE( retrieve_constraint )
|
|||
BOOST_CHECK_EQUAL( i, &j );
|
||||
}
|
||||
#endif
|
||||
#ifdef MOCK_SMART_PTR
|
||||
{
|
||||
std::unique_ptr< int > i;
|
||||
std::unique_ptr< int > j( new int( 3 ) );
|
||||
BOOST_CHECK( mock::retrieve( i ).c_( j ) );
|
||||
BOOST_REQUIRE( i );
|
||||
BOOST_CHECK_EQUAL( 3, *i );
|
||||
BOOST_CHECK( !j );
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
namespace
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue