Reverting revision 21

git-svn-id: https://svn.code.sf.net/p/turtle/code/trunk@24 860be788-9bd5-4423-9f1e-828f051e677b
This commit is contained in:
mat007 2009-09-06 17:49:13 +00:00
parent f98339ea9d
commit 1d13a3fcde
3 changed files with 6 additions and 9 deletions

View file

@ -46,11 +46,11 @@ namespace mock
matcher_type;
public:
expectation( node& parent = detail::root, const std::string& name = "?" )
expectation( node& parent = root, const std::string& name = "?" )
: impl_( new expectation_impl( parent, name ) )
{}
expectation( const std::string& name )
: impl_( new expectation_impl( detail::root, name ) )
: impl_( new expectation_impl( root, name ) )
{}
expectation& set_name( const std::string& name )

View file

@ -19,12 +19,12 @@ namespace mock
class object : public node
{
public:
explicit object( node& parent = detail::root, const std::string& name = "" )
explicit object( node& parent = root, const std::string& name = "" )
: node( parent )
, name_( name )
{}
explicit object( const std::string& name )
: node( detail::root )
: node( root )
, name_( name )
{}

View file

@ -13,8 +13,6 @@
#include <boost/test/utils/trivial_singleton.hpp>
namespace mock
{
namespace detail
{
class root_t : public boost::unit_test::singleton< root_t >, public node
{
@ -24,15 +22,14 @@ namespace detail
BOOST_TEST_SINGLETON_CONS( root_t );
};
BOOST_TEST_SINGLETON_INST( root )
}
inline bool verify()
{
return detail::root.verify();
return root.verify();
}
inline void reset()
{
detail::root.reset();
root.reset();
}
}