Merge remote-tracking branch 'origin/master'

Conflicts:
	README.md
	include/internal/catch_version.hpp
	single_include/catch.hpp
This commit is contained in:
dmitry.trifonov
2013-10-27 21:32:15 +04:00
18 changed files with 2560 additions and 191 deletions

View File

@@ -17,7 +17,7 @@ namespace Catch {
class Context : public IMutableContext {
Context() : m_config( NULL ) {}
Context() : m_config( NULL ), m_runner( NULL ), m_resultCapture( NULL ) {}
Context( Context const& );
void operator=( Context const& );
@@ -77,9 +77,9 @@ namespace Catch {
}
private:
Ptr<IConfig const> m_config;
IRunner* m_runner;
IResultCapture* m_resultCapture;
Ptr<IConfig const> m_config;
std::map<std::string, IGeneratorsForTest*> m_generatorsByTestName;
};

View File

@@ -58,7 +58,7 @@ namespace Catch {
matchedTests++;
Text nameWrapper( it->getTestCaseInfo().name,
TextAttributes()
.setWidth( maxNameLen )
.setWidth( maxNameLen+2 )
.setInitialIndent(2)
.setIndent(4) );

View File

@@ -23,7 +23,10 @@ namespace Catch {
std::string remainder = _str;
while( !remainder.empty() ) {
assert( lines.size() < 1000 );
if( lines.size() >= 1000 ) {
lines.push_back( "... message truncated due to excessive size" );
return;
}
std::size_t tabPos = std::string::npos;
std::size_t width = (std::min)( remainder.size(), _attr.width - indent );
std::size_t pos = remainder.find_first_of( '\n' );