mirror of
https://github.com/catchorg/Catch2.git
synced 2025-05-30 08:27:52 +00:00
Build 37
- string matchers work with NULLs - removed stray CATCH_CONFIG_SFINAE for GCC 3
This commit is contained in:
parent
06548a5b61
commit
d0d4d93a6b
4 changed files with 69 additions and 18 deletions
|
@ -1,6 +1,6 @@
|
|||
/*
|
||||
* CATCH v0.9 build 36 (integration branch)
|
||||
* Generated: 2013-04-22 18:53:02.845247
|
||||
* CATCH v0.9 build 37 (integration branch)
|
||||
* Generated: 2013-04-23 08:01:34.500704
|
||||
* ----------------------------------------------------------
|
||||
* This file has been merged from multiple headers. Please don't edit it directly
|
||||
* Copyright (c) 2012 Two Blue Cubes Ltd. All rights reserved.
|
||||
|
@ -406,7 +406,7 @@ namespace Catch {
|
|||
#if __GNUC__ < 3
|
||||
|
||||
#if (__GNUC_MINOR__ >= 96 )
|
||||
#define CATCH_CONFIG_SFINAE
|
||||
//#define CATCH_CONFIG_SFINAE
|
||||
#endif
|
||||
|
||||
#elif __GNUC__ >= 3
|
||||
|
@ -3237,6 +3237,9 @@ namespace Matchers {
|
|||
|
||||
namespace StdString {
|
||||
|
||||
inline std::string makeString( const std::string& str ) { return str; }
|
||||
inline std::string makeString( const char* str ) { return str ? std::string( str ) : std::string(); }
|
||||
|
||||
struct Equals : MatcherImpl<Equals, std::string> {
|
||||
Equals( const std::string& str ) : m_str( str ){}
|
||||
Equals( const Equals& other ) : m_str( other.m_str ){}
|
||||
|
@ -3328,10 +3331,30 @@ namespace Matchers {
|
|||
return Impl::Generic::AnyOf<ExpressionT>().add( m1 ).add( m2 ).add( m3 );
|
||||
}
|
||||
|
||||
inline Impl::StdString::Equals Equals( const std::string& str ){ return Impl::StdString::Equals( str ); }
|
||||
inline Impl::StdString::Contains Contains( const std::string& substr ){ return Impl::StdString::Contains( substr ); }
|
||||
inline Impl::StdString::StartsWith StartsWith( const std::string& substr ){ return Impl::StdString::StartsWith( substr ); }
|
||||
inline Impl::StdString::EndsWith EndsWith( const std::string& substr ){ return Impl::StdString::EndsWith( substr ); }
|
||||
inline Impl::StdString::Equals Equals( const std::string& str ) {
|
||||
return Impl::StdString::Equals( str );
|
||||
}
|
||||
inline Impl::StdString::Equals Equals( const char* str ) {
|
||||
return Impl::StdString::Equals( Impl::StdString::makeString( str ) );
|
||||
}
|
||||
inline Impl::StdString::Contains Contains( const std::string& substr ) {
|
||||
return Impl::StdString::Contains( substr );
|
||||
}
|
||||
inline Impl::StdString::Contains Contains( const char* substr ) {
|
||||
return Impl::StdString::Contains( Impl::StdString::makeString( substr ) );
|
||||
}
|
||||
inline Impl::StdString::StartsWith StartsWith( const std::string& substr ) {
|
||||
return Impl::StdString::StartsWith( substr );
|
||||
}
|
||||
inline Impl::StdString::StartsWith StartsWith( const char* substr ) {
|
||||
return Impl::StdString::StartsWith( Impl::StdString::makeString( substr ) );
|
||||
}
|
||||
inline Impl::StdString::EndsWith EndsWith( const std::string& substr ) {
|
||||
return Impl::StdString::EndsWith( substr );
|
||||
}
|
||||
inline Impl::StdString::EndsWith EndsWith( const char* substr ) {
|
||||
return Impl::StdString::EndsWith( Impl::StdString::makeString( substr ) );
|
||||
}
|
||||
|
||||
} // namespace Matchers
|
||||
|
||||
|
@ -6172,7 +6195,7 @@ namespace Catch {
|
|||
namespace Catch {
|
||||
|
||||
// These numbers are maintained by a script
|
||||
Version libraryVersion( 0, 9, 36, "integration" );
|
||||
Version libraryVersion( 0, 9, 37, "integration" );
|
||||
}
|
||||
|
||||
// #included from: catch_text.hpp
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue