Merge branch 'master' into master
This commit is contained in:
		
						commit
						d5525cdcf8
					
				@ -36,11 +36,8 @@ compiler:
 | 
			
		||||
script: ./travis.sh
 | 
			
		||||
env:
 | 
			
		||||
  matrix:
 | 
			
		||||
    - GTEST_TARGET=googletest SHARED_LIB=OFF STATIC_LIB=ON CMAKE_PKG=OFF BUILD_TYPE=debug   VERBOSE_MAKE=true VERBOSE
 | 
			
		||||
    - GTEST_TARGET=googlemock SHARED_LIB=OFF STATIC_LIB=ON CMAKE_PKG=OFF BUILD_TYPE=debug   VERBOSE_MAKE=true VERBOSE
 | 
			
		||||
    - GTEST_TARGET=googlemock SHARED_LIB=OFF STATIC_LIB=ON CMAKE_PKG=OFF BUILD_TYPE=debug CXX_FLAGS=-std=c++11  VERBOSE_MAKE=true VERBOSE
 | 
			
		||||
#    - GTEST_TARGET=googletest SHARED_LIB=ON  STATIC_LIB=ON CMAKE_PKG=ON  BUILD_TYPE=release VERBOSE_MAKE=false
 | 
			
		||||
#    - GTEST_TARGET=googlemock SHARED_LIB=ON  STATIC_LIB=ON CMAKE_PKG=ON  BUILD_TYPE=release VERBOSE_MAKE=false
 | 
			
		||||
    - SHARED_LIB=OFF STATIC_LIB=ON CMAKE_PKG=OFF BUILD_TYPE=debug VERBOSE=1
 | 
			
		||||
    - SHARED_LIB=OFF STATIC_LIB=ON CMAKE_PKG=OFF BUILD_TYPE=debug VERBOSE=1 CXX_FLAGS=-std=c++11
 | 
			
		||||
notifications:
 | 
			
		||||
  email: false
 | 
			
		||||
sudo: false
 | 
			
		||||
 | 
			
		||||
@ -26,7 +26,7 @@ in its interior [googletest/README.md](googletest/README.md) file.
 | 
			
		||||
 | 
			
		||||
## Features ##
 | 
			
		||||
 | 
			
		||||
  * An [XUnit](https://en.wikipedia.org/wiki/XUnit) test framework.
 | 
			
		||||
  * An [xUnit](https://en.wikipedia.org/wiki/XUnit) test framework.
 | 
			
		||||
  * Test discovery.
 | 
			
		||||
  * A rich set of assertions.
 | 
			
		||||
  * User-defined assertions.
 | 
			
		||||
 | 
			
		||||
@ -148,7 +148,7 @@ Note that the mock class doesn't define `AppendPacket()`, unlike the
 | 
			
		||||
real class. That's fine as long as the test doesn't need to call it.
 | 
			
		||||
 | 
			
		||||
Next, you need a way to say that you want to use
 | 
			
		||||
`ConcretePacketStream` in production code, and use `MockPacketStream`
 | 
			
		||||
`ConcretePacketStream` in production code and to use `MockPacketStream`
 | 
			
		||||
in tests.  Since the functions are not virtual and the two classes are
 | 
			
		||||
unrelated, you must specify your choice at _compile time_ (as opposed
 | 
			
		||||
to run time).
 | 
			
		||||
@ -706,7 +706,7 @@ type `m` accepts):
 | 
			
		||||
  1. When both `T` and `U` are built-in arithmetic types (`bool`, integers, and floating-point numbers), the conversion from `T` to `U` is not lossy (in other words, any value representable by `T` can also be represented by `U`); and
 | 
			
		||||
  1. When `U` is a reference, `T` must also be a reference (as the underlying matcher may be interested in the address of the `U` value).
 | 
			
		||||
 | 
			
		||||
The code won't compile if any of these conditions isn't met.
 | 
			
		||||
The code won't compile if any of these conditions aren't met.
 | 
			
		||||
 | 
			
		||||
Here's one example:
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
@ -1623,8 +1623,8 @@ printf("We are in test %s of test case %s.\n",
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
`current_test_info()` returns a null pointer if no test is running. In
 | 
			
		||||
particular, you cannot find the test case name in `TestCaseSetUp()`,
 | 
			
		||||
`TestCaseTearDown()` (where you know the test case name implicitly), or
 | 
			
		||||
particular, you cannot find the test case name in `SetUpTestCase()`,
 | 
			
		||||
`TearDownTestCase()` (where you know the test case name implicitly), or
 | 
			
		||||
functions called from them.
 | 
			
		||||
 | 
			
		||||
_Availability:_ Linux, Windows, Mac.
 | 
			
		||||
 | 
			
		||||
@ -3115,13 +3115,13 @@ TEST(DISABLED_TestCase, DISABLED_TestShouldNotRun) {
 | 
			
		||||
  FAIL() << "Unexpected failure: Test in disabled test case should not be run.";
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
// Check that when all tests in a test case are disabled, SetupTestCase() and
 | 
			
		||||
// Check that when all tests in a test case are disabled, SetUpTestCase() and
 | 
			
		||||
// TearDownTestCase() are not called.
 | 
			
		||||
class DisabledTestsTest : public Test {
 | 
			
		||||
 protected:
 | 
			
		||||
  static void SetUpTestCase() {
 | 
			
		||||
    FAIL() << "Unexpected failure: All tests disabled in test case. "
 | 
			
		||||
              "SetupTestCase() should not be called.";
 | 
			
		||||
              "SetUpTestCase() should not be called.";
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  static void TearDownTestCase() {
 | 
			
		||||
 | 
			
		||||
@ -3,13 +3,12 @@ set -evx
 | 
			
		||||
env | sort
 | 
			
		||||
 | 
			
		||||
mkdir build || true
 | 
			
		||||
mkdir build/$GTEST_TARGET || true
 | 
			
		||||
cd build/$GTEST_TARGET
 | 
			
		||||
cd build
 | 
			
		||||
cmake -Dgtest_build_samples=ON \
 | 
			
		||||
      -Dgmock_build_samples=ON \
 | 
			
		||||
      -Dgtest_build_tests=ON \
 | 
			
		||||
      -Dgmock_build_tests=ON \
 | 
			
		||||
      -DCMAKE_CXX_FLAGS=$CXX_FLAGS \
 | 
			
		||||
      ../../$GTEST_TARGET
 | 
			
		||||
      ..
 | 
			
		||||
make
 | 
			
		||||
CTEST_OUTPUT_ON_FAILURE=1 make test
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user