Merge pull request #1385 from gennadiycivil/master
code cleanup in preparation for merges, cl 180857299
This commit is contained in:
commit
4371b996ed
@ -305,14 +305,14 @@ void DieWithEmbeddedNul() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
# if GTEST_USES_PCRE
|
# if GTEST_USES_PCRE
|
||||||
|
|
||||||
// Tests that EXPECT_DEATH and ASSERT_DEATH work when the error
|
// Tests that EXPECT_DEATH and ASSERT_DEATH work when the error
|
||||||
// message has a NUL character in it.
|
// message has a NUL character in it.
|
||||||
TEST_F(TestForDeathTest, EmbeddedNulInMessage) {
|
TEST_F(TestForDeathTest, EmbeddedNulInMessage) {
|
||||||
// TODO(wan@google.com): <regex.h> doesn't support matching strings
|
|
||||||
// with embedded NUL characters - find a way to workaround it.
|
|
||||||
EXPECT_DEATH(DieWithEmbeddedNul(), "my null world");
|
EXPECT_DEATH(DieWithEmbeddedNul(), "my null world");
|
||||||
ASSERT_DEATH(DieWithEmbeddedNul(), "my null world");
|
ASSERT_DEATH(DieWithEmbeddedNul(), "my null world");
|
||||||
}
|
}
|
||||||
|
|
||||||
# endif // GTEST_USES_PCRE
|
# endif // GTEST_USES_PCRE
|
||||||
|
|
||||||
// Tests that death test macros expand to code which interacts well with switch
|
// Tests that death test macros expand to code which interacts well with switch
|
||||||
|
@ -27,16 +27,14 @@
|
|||||||
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||||
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
//
|
//
|
||||||
// Authors: keith.ray@gmail.com (Keith Ray)
|
|
||||||
//
|
//
|
||||||
// Google Test filepath utilities
|
// Google Test filepath utilities
|
||||||
//
|
//
|
||||||
// This file tests classes and functions used internally by
|
// This file tests classes and functions used internally by
|
||||||
// Google Test. They are subject to change without notice.
|
// Google Test. They are subject to change without notice.
|
||||||
//
|
//
|
||||||
// This file is #included from gtest_unittest.cc, to avoid changing
|
// This file is #included from gtest-internal.h.
|
||||||
// build or make-files for some existing Google Test clients. Do not
|
// Do not #include this file anywhere else!
|
||||||
// #include this file anywhere else!
|
|
||||||
|
|
||||||
#include "gtest/internal/gtest-filepath.h"
|
#include "gtest/internal/gtest-filepath.h"
|
||||||
#include "gtest/gtest.h"
|
#include "gtest/gtest.h"
|
||||||
|
@ -27,7 +27,6 @@
|
|||||||
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||||
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
//
|
//
|
||||||
// Authors: keith.ray@gmail.com (Keith Ray)
|
|
||||||
//
|
//
|
||||||
// Google Test UnitTestOptions tests
|
// Google Test UnitTestOptions tests
|
||||||
//
|
//
|
||||||
|
@ -59,3 +59,4 @@ INSTANTIATE_TEST_CASE_P(MultiplesOf33,
|
|||||||
INSTANTIATE_TEST_CASE_P(Sequence2,
|
INSTANTIATE_TEST_CASE_P(Sequence2,
|
||||||
InstantiationInMultipleTranslaionUnitsTest,
|
InstantiationInMultipleTranslaionUnitsTest,
|
||||||
Values(42*3, 42*4, 42*5));
|
Values(42*3, 42*4, 42*5));
|
||||||
|
|
||||||
|
@ -67,8 +67,8 @@ TEST(IsXDigitTest, WorksForNarrowAscii) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
TEST(IsXDigitTest, ReturnsFalseForNarrowNonAscii) {
|
TEST(IsXDigitTest, ReturnsFalseForNarrowNonAscii) {
|
||||||
EXPECT_FALSE(IsXDigit('\x80'));
|
EXPECT_FALSE(IsXDigit(static_cast<char>(0x80)));
|
||||||
EXPECT_FALSE(IsXDigit(static_cast<char>('0' | '\x80')));
|
EXPECT_FALSE(IsXDigit(static_cast<char>('0' | 0x80)));
|
||||||
}
|
}
|
||||||
|
|
||||||
TEST(IsXDigitTest, WorksForWideAscii) {
|
TEST(IsXDigitTest, WorksForWideAscii) {
|
||||||
|
@ -80,8 +80,7 @@ int main(int argc, char **argv) {
|
|||||||
SetUnhandledExceptionFilter(ExitWithExceptionCode);
|
SetUnhandledExceptionFilter(ExitWithExceptionCode);
|
||||||
|
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif // GTEST_OS_WINDOWS
|
||||||
|
|
||||||
testing::InitGoogleTest(&argc, argv);
|
testing::InitGoogleTest(&argc, argv);
|
||||||
|
|
||||||
return RUN_ALL_TESTS();
|
return RUN_ALL_TESTS();
|
||||||
|
@ -210,6 +210,7 @@ void TestRepeatWithFilterForFailedTests(int repeat) {
|
|||||||
|
|
||||||
int main(int argc, char **argv) {
|
int main(int argc, char **argv) {
|
||||||
testing::InitGoogleTest(&argc, argv);
|
testing::InitGoogleTest(&argc, argv);
|
||||||
|
|
||||||
testing::AddGlobalTestEnvironment(new MyEnvironment);
|
testing::AddGlobalTestEnvironment(new MyEnvironment);
|
||||||
|
|
||||||
TestRepeatUnspecified();
|
TestRepeatUnspecified();
|
||||||
|
@ -34,7 +34,6 @@
|
|||||||
|
|
||||||
#include "gtest/gtest.h"
|
#include "gtest/gtest.h"
|
||||||
|
|
||||||
#include <iostream>
|
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "src/gtest-internal-inl.h"
|
#include "src/gtest-internal-inl.h"
|
||||||
|
@ -27,7 +27,6 @@
|
|||||||
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||||
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
//
|
//
|
||||||
// Author: keith.ray@gmail.com (Keith Ray)
|
|
||||||
//
|
//
|
||||||
// gtest_xml_outfile1_test_ writes some xml via TestProperty used by
|
// gtest_xml_outfile1_test_ writes some xml via TestProperty used by
|
||||||
// gtest_xml_outfiles_test.py
|
// gtest_xml_outfiles_test.py
|
||||||
|
@ -27,7 +27,6 @@
|
|||||||
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||||
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
//
|
//
|
||||||
// Author: keith.ray@gmail.com (Keith Ray)
|
|
||||||
//
|
//
|
||||||
// gtest_xml_outfile2_test_ writes some xml via TestProperty used by
|
// gtest_xml_outfile2_test_ writes some xml via TestProperty used by
|
||||||
// gtest_xml_outfiles_test.py
|
// gtest_xml_outfiles_test.py
|
||||||
|
@ -27,8 +27,6 @@
|
|||||||
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||||
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
|
|
||||||
// Author: eefacm@gmail.com (Sean Mcafee)
|
|
||||||
|
|
||||||
// Unit test for Google Test XML output.
|
// Unit test for Google Test XML output.
|
||||||
//
|
//
|
||||||
// A user can specify XML output in a Google Test program to run via
|
// A user can specify XML output in a Google Test program to run via
|
||||||
|
Loading…
Reference in New Issue
Block a user