mirror of
https://github.com/catchorg/Catch2.git
synced 2025-09-22 04:25:40 +02:00
Compare commits
6 Commits
Author | SHA1 | Date | |
---|---|---|---|
![]() |
6860c8def0 | ||
![]() |
3255ee6312 | ||
![]() |
74effafca7 | ||
![]() |
7d0cfd27ce | ||
![]() |
3fe4d394a5 | ||
![]() |
b97e9a2f8b |
@@ -3,9 +3,9 @@
|
|||||||
[](https://github.com/philsquared/catch/releases)
|
[](https://github.com/philsquared/catch/releases)
|
||||||
[](https://travis-ci.org/philsquared/Catch)
|
[](https://travis-ci.org/philsquared/Catch)
|
||||||
[](https://ci.appveyor.com/project/philsquared/catch/branch/master)
|
[](https://ci.appveyor.com/project/philsquared/catch/branch/master)
|
||||||
[](https://wandbox.org/permlink/hgiYhcvH835lHvaA)
|
[](https://wandbox.org/permlink/jG7wnHX9VAcxpSHy)
|
||||||
|
|
||||||
<a href="https://github.com/philsquared/Catch/releases/download/v1.12.0/catch.hpp">The latest, single header, version can be downloaded directly using this link</a>
|
<a href="https://github.com/philsquared/Catch/releases/download/v1.12.2/catch.hpp">The latest, single header, version can be downloaded directly using this link</a>
|
||||||
|
|
||||||
## What's the Catch?
|
## What's the Catch?
|
||||||
|
|
||||||
|
@@ -4,7 +4,7 @@ from conans import ConanFile
|
|||||||
|
|
||||||
class CatchConan(ConanFile):
|
class CatchConan(ConanFile):
|
||||||
name = "Catch"
|
name = "Catch"
|
||||||
version = "1.12.0"
|
version = "1.12.2"
|
||||||
description = "A modern, C++-native, header-only, framework for unit-tests, TDD and BDD"
|
description = "A modern, C++-native, header-only, framework for unit-tests, TDD and BDD"
|
||||||
author = "philsquared"
|
author = "philsquared"
|
||||||
generators = "cmake"
|
generators = "cmake"
|
||||||
|
@@ -1,3 +1,16 @@
|
|||||||
|
# 1.12.2
|
||||||
|
### Fixes
|
||||||
|
* Fixed missing <cassert> include
|
||||||
|
|
||||||
|
# 1.12.1
|
||||||
|
|
||||||
|
### Fixes
|
||||||
|
* Fixed deprecation warning in `ScopedMessage::~ScopedMessage`
|
||||||
|
* All uses of `min` or `max` identifiers are now wrapped in parentheses
|
||||||
|
* This avoids problems when Windows headers define `min` and `max` macros
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# 1.12.0
|
# 1.12.0
|
||||||
|
|
||||||
### Fixes
|
### Fixes
|
||||||
|
@@ -37,11 +37,18 @@ namespace Catch {
|
|||||||
: m_info( other.m_info )
|
: m_info( other.m_info )
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
#if defined(_MSC_VER)
|
||||||
|
#pragma warning(push)
|
||||||
|
#pragma warning(disable:4996) // std::uncaught_exception is deprecated in C++17
|
||||||
|
#endif
|
||||||
ScopedMessage::~ScopedMessage() {
|
ScopedMessage::~ScopedMessage() {
|
||||||
if ( !std::uncaught_exception() ){
|
if ( !std::uncaught_exception() ){
|
||||||
getResultCapture().popScopedMessage(m_info);
|
getResultCapture().popScopedMessage(m_info);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#if defined(_MSC_VER)
|
||||||
|
#pragma warning(pop)
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
} // end namespace Catch
|
} // end namespace Catch
|
||||||
|
@@ -16,6 +16,8 @@
|
|||||||
#include "catch_interfaces_registry_hub.h"
|
#include "catch_interfaces_registry_hub.h"
|
||||||
#include "catch_wildcard_pattern.hpp"
|
#include "catch_wildcard_pattern.hpp"
|
||||||
|
|
||||||
|
#include <cassert>
|
||||||
|
|
||||||
namespace Catch {
|
namespace Catch {
|
||||||
|
|
||||||
ResultBuilder::ResultBuilder( char const* macroName,
|
ResultBuilder::ResultBuilder( char const* macroName,
|
||||||
|
@@ -22,7 +22,7 @@
|
|||||||
#include "catch_result_builder.h"
|
#include "catch_result_builder.h"
|
||||||
#include "catch_fatal_condition.hpp"
|
#include "catch_fatal_condition.hpp"
|
||||||
|
|
||||||
|
#include <cassert>
|
||||||
#include <set>
|
#include <set>
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
|
@@ -27,9 +27,9 @@ namespace Catch {
|
|||||||
result_type operator()( result_type n ) const { return std::rand() % n; }
|
result_type operator()( result_type n ) const { return std::rand() % n; }
|
||||||
|
|
||||||
#ifdef CATCH_CONFIG_CPP11_SHUFFLE
|
#ifdef CATCH_CONFIG_CPP11_SHUFFLE
|
||||||
static constexpr result_type min() { return 0; }
|
static constexpr result_type (min)() { return 0; }
|
||||||
static constexpr result_type max() { return 1000000; }
|
static constexpr result_type (max)() { return 1000000; }
|
||||||
result_type operator()() const { return std::rand() % max(); }
|
result_type operator()() const { return std::rand() % (max)(); }
|
||||||
#endif
|
#endif
|
||||||
template<typename V>
|
template<typename V>
|
||||||
static void shuffle( V& vector ) {
|
static void shuffle( V& vector ) {
|
||||||
|
@@ -38,7 +38,7 @@ namespace Catch {
|
|||||||
}
|
}
|
||||||
|
|
||||||
inline Version libraryVersion() {
|
inline Version libraryVersion() {
|
||||||
static Version version( 1, 12, 0, "", 0 );
|
static Version version( 1, 12, 2, "", 0 );
|
||||||
return version;
|
return version;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -13,6 +13,7 @@
|
|||||||
#include "../internal/catch_reporter_registrars.hpp"
|
#include "../internal/catch_reporter_registrars.hpp"
|
||||||
#include "../internal/catch_console_colour.hpp"
|
#include "../internal/catch_console_colour.hpp"
|
||||||
|
|
||||||
|
#include <cassert>
|
||||||
#include <cfloat>
|
#include <cfloat>
|
||||||
#include <cstdio>
|
#include <cstdio>
|
||||||
|
|
||||||
|
@@ -14,6 +14,7 @@
|
|||||||
// file can be distributed as a single header that works with the main
|
// file can be distributed as a single header that works with the main
|
||||||
// Catch single header.
|
// Catch single header.
|
||||||
|
|
||||||
|
#include <cassert>
|
||||||
#include <cstring>
|
#include <cstring>
|
||||||
|
|
||||||
#ifdef __clang__
|
#ifdef __clang__
|
||||||
|
@@ -8,7 +8,7 @@ from releaseCommon import Version
|
|||||||
|
|
||||||
print(catchPath)
|
print(catchPath)
|
||||||
|
|
||||||
default_path = '../vcpkg/ports/catch/'
|
default_path = '../vcpkg/ports/catch-classic/'
|
||||||
|
|
||||||
def adjusted_path(path):
|
def adjusted_path(path):
|
||||||
return os.path.join(catchPath, path)
|
return os.path.join(catchPath, path)
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
/*
|
/*
|
||||||
* Catch v1.12.0
|
* Catch v1.12.2
|
||||||
* Generated: 2018-01-11 21:56:34.893972
|
* Generated: 2018-05-14 15:10:01.112442
|
||||||
* ----------------------------------------------------------
|
* ----------------------------------------------------------
|
||||||
* This file has been merged from multiple headers. Please don't edit it directly
|
* This file has been merged from multiple headers. Please don't edit it directly
|
||||||
* Copyright (c) 2012 Two Blue Cubes Ltd. All rights reserved.
|
* Copyright (c) 2012 Two Blue Cubes Ltd. All rights reserved.
|
||||||
@@ -6599,6 +6599,7 @@ namespace Catch {
|
|||||||
|
|
||||||
#endif // not Windows
|
#endif // not Windows
|
||||||
|
|
||||||
|
#include <cassert>
|
||||||
#include <set>
|
#include <set>
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
@@ -7292,9 +7293,9 @@ namespace Catch {
|
|||||||
result_type operator()( result_type n ) const { return std::rand() % n; }
|
result_type operator()( result_type n ) const { return std::rand() % n; }
|
||||||
|
|
||||||
#ifdef CATCH_CONFIG_CPP11_SHUFFLE
|
#ifdef CATCH_CONFIG_CPP11_SHUFFLE
|
||||||
static constexpr result_type min() { return 0; }
|
static constexpr result_type (min)() { return 0; }
|
||||||
static constexpr result_type max() { return 1000000; }
|
static constexpr result_type (max)() { return 1000000; }
|
||||||
result_type operator()() const { return std::rand() % max(); }
|
result_type operator()() const { return std::rand() % (max)(); }
|
||||||
#endif
|
#endif
|
||||||
template<typename V>
|
template<typename V>
|
||||||
static void shuffle( V& vector ) {
|
static void shuffle( V& vector ) {
|
||||||
@@ -8466,7 +8467,7 @@ namespace Catch {
|
|||||||
}
|
}
|
||||||
|
|
||||||
inline Version libraryVersion() {
|
inline Version libraryVersion() {
|
||||||
static Version version( 1, 12, 0, "", 0 );
|
static Version version( 1, 12, 2, "", 0 );
|
||||||
return version;
|
return version;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -8501,11 +8502,18 @@ namespace Catch {
|
|||||||
: m_info( other.m_info )
|
: m_info( other.m_info )
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
#if defined(_MSC_VER)
|
||||||
|
#pragma warning(push)
|
||||||
|
#pragma warning(disable:4996) // std::uncaught_exception is deprecated in C++17
|
||||||
|
#endif
|
||||||
ScopedMessage::~ScopedMessage() {
|
ScopedMessage::~ScopedMessage() {
|
||||||
if ( !std::uncaught_exception() ){
|
if ( !std::uncaught_exception() ){
|
||||||
getResultCapture().popScopedMessage(m_info);
|
getResultCapture().popScopedMessage(m_info);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#if defined(_MSC_VER)
|
||||||
|
#pragma warning(pop)
|
||||||
|
#endif
|
||||||
|
|
||||||
} // end namespace Catch
|
} // end namespace Catch
|
||||||
|
|
||||||
@@ -9164,6 +9172,8 @@ std::string toString( std::nullptr_t ) {
|
|||||||
// #included from: catch_result_builder.hpp
|
// #included from: catch_result_builder.hpp
|
||||||
#define TWOBLUECUBES_CATCH_RESULT_BUILDER_HPP_INCLUDED
|
#define TWOBLUECUBES_CATCH_RESULT_BUILDER_HPP_INCLUDED
|
||||||
|
|
||||||
|
#include <cassert>
|
||||||
|
|
||||||
namespace Catch {
|
namespace Catch {
|
||||||
|
|
||||||
ResultBuilder::ResultBuilder( char const* macroName,
|
ResultBuilder::ResultBuilder( char const* macroName,
|
||||||
@@ -10657,6 +10667,7 @@ namespace Catch {
|
|||||||
// #included from: ../reporters/catch_reporter_console.hpp
|
// #included from: ../reporters/catch_reporter_console.hpp
|
||||||
#define TWOBLUECUBES_CATCH_REPORTER_CONSOLE_HPP_INCLUDED
|
#define TWOBLUECUBES_CATCH_REPORTER_CONSOLE_HPP_INCLUDED
|
||||||
|
|
||||||
|
#include <cassert>
|
||||||
#include <cfloat>
|
#include <cfloat>
|
||||||
#include <cstdio>
|
#include <cstdio>
|
||||||
|
|
||||||
|
@@ -10,7 +10,7 @@ class CatchConanTest(ConanFile):
|
|||||||
settings = "os", "compiler", "arch", "build_type"
|
settings = "os", "compiler", "arch", "build_type"
|
||||||
username = getenv("CONAN_USERNAME", "philsquared")
|
username = getenv("CONAN_USERNAME", "philsquared")
|
||||||
channel = getenv("CONAN_CHANNEL", "testing")
|
channel = getenv("CONAN_CHANNEL", "testing")
|
||||||
requires = "Catch/1.12.0@%s/%s" % (username, channel)
|
requires = "Catch/1.12.2@%s/%s" % (username, channel)
|
||||||
|
|
||||||
def build(self):
|
def build(self):
|
||||||
cmake = CMake(self)
|
cmake = CMake(self)
|
||||||
|
Reference in New Issue
Block a user