"docs/gmock_cheat_sheet.md" did not exist on "adeef192947fbc0f68fa14a6c494c8df32177508"
  1. 16 Apr, 2020 8 commits
    • Arthur O'Dwyer's avatar
      VariadicMatcher needs a non-defaulted move constructor for compile-time performance. · 4f002f1e
      Arthur O'Dwyer authored
      We are about to remove all uses of GTEST_DISALLOW_ASSIGN_ in favor
      of using the Rule of Zero everywhere.
      
      Unfortunately, if we use the Rule of Zero here, then when the compiler
      needs to figure out if VariadicMatcher is move-constructible, it will
      recurse down into `tuple<Args...>`, which on libstdc++ recurses too deeply.
      
          In file included from googlemock/test/gmock-matchers_test.cc:43:
          In file included from googlemock/include/gmock/gmock-matchers.h:258:
          In file included from /usr/include/c++/5.5.0/algorithm:60:
          In file included from /usr/include/c++/5.5.0/utility:70:
          In file included from /usr/include/c++/5.5.0/bits/stl_pair.h:59:
          In file included from /usr/include/c++/5.5.0/bits/move.h:57:
          /usr/bin/include/c++/5.5.0/type_traits:115:26: fatal error:
                recursive template instantiation exceeded maximum depth of 256
              : public conditional<_B1::value, _B1, _B2>::type
                                   ^
      
      The move constructor is the only problematic case, for some unknown reason.
      With GTEST_DISALLOW_ASSIGN_, the presence of a copy assignment operator
      causes the move constructor to be non-declared, thus non-defaulted, thus
      non-problematic. Without GTEST_DISALLOW_ASSIGN_, we have to do one of the
      following:
      
      - Default the copy constructor, so that the move constructor will be non-declared.
      
      - Define our own non-defaulted move constructor.
      
      ...except that doing the latter STILL did not work!
      Fortunately, the former (default the copy constructor, don't provide
      any move constructor) both works in practice and is semantically
      equivalent to the old code.
      4f002f1e
    • Mark Barolak's avatar
      Merge pull request #2805 from pepsiman:patch-1 · dcc92d0a
      Mark Barolak authored
      PiperOrigin-RevId: 306462650
      dcc92d0a
    • Mark Barolak's avatar
      Merge pull request #2802 from e-i-n-s:fix_clang_warning · 71d5df6c
      Mark Barolak authored
      PiperOrigin-RevId: 306460942
      71d5df6c
    • Mark Barolak's avatar
      Merge pull request #2810 from ptahmose:master · 4c8e6a9f
      Mark Barolak authored
      PiperOrigin-RevId: 306460738
      4c8e6a9f
    • Abseil Team's avatar
      Googletest export · 373d72b6
      Abseil Team authored
      Fix link to "After clause". Sorry, reader, but this heading is in another document!
      
      PiperOrigin-RevId: 305947971
      373d72b6
    • Mark Barolak's avatar
      Merge pull request #2756 from Conan-Kudo:fix-pkgconfig-reqs · 4fe5ac53
      Mark Barolak authored
      PiperOrigin-RevId: 305747437
      4fe5ac53
    • Mark Barolak's avatar
      Merge pull request #2772 from Quuxplusone:travis · c2032090
      Mark Barolak authored
      PiperOrigin-RevId: 305747317
      c2032090
    • Mark Barolak's avatar
      Merge pull request #2773 from Quuxplusone:replace-noexcept · b51a49e0
      Mark Barolak authored
      PiperOrigin-RevId: 305707266
      b51a49e0
  2. 12 Apr, 2020 1 commit
  3. 09 Apr, 2020 1 commit
  4. 07 Apr, 2020 1 commit
  5. 04 Apr, 2020 3 commits
  6. 31 Mar, 2020 3 commits
  7. 28 Mar, 2020 2 commits
    • Arthur O'Dwyer's avatar
      Replace the last instance of `throw()` with `noexcept`. NFC. · 6ed4e716
      Arthur O'Dwyer authored
      Fixes a -Wdeprecated warning.
      
      /home/travis/build/Quuxplusone/googletest/googletest/test/googletest-death-test_ex_test.cc:62:28: error:
            dynamic exception specifications are deprecated [-Werror,-Wdeprecated]
        const char* what() const throw() override { return "exceptional message"; }
                                 ^~~~~~~
      /home/travis/build/Quuxplusone/googletest/googletest/test/googletest-death-test_ex_test.cc:62:28: note:
            use 'noexcept' instead
        const char* what() const throw() override { return "exceptional message"; }
                                 ^~~~~~~
                                 noexcept
      6ed4e716
    • Arthur O'Dwyer's avatar
      Fix a typo in .travis.yml · 5504ded3
      Arthur O'Dwyer authored
      The old code was trying to pass -Wgnu-zero-variadic-macro-arguments
      as part of CXXFLAGS, but it forgot the quotation marks needed around
      whitespace. This meant that option was ignored:
      https://travis-ci.org/github/google/googletest/jobs/666534177#L760
      
      Unfortunately, the codebase is not remotely clean with respect to that
      warning option. It fails like this:
      https://travis-ci.org/github/Quuxplusone/googletest/jobs/668118135
      
      So, remove that failing configuration from the test matrix until
      someone has time to look at it.
      5504ded3
  8. 24 Mar, 2020 5 commits
  9. 21 Mar, 2020 3 commits
  10. 18 Mar, 2020 2 commits
  11. 17 Mar, 2020 8 commits
  12. 11 Mar, 2020 1 commit
    • Romain Geissler's avatar
      Make sure IsATTY does not clobber errno. · a1b0173d
      Romain Geissler authored
      Exposition of the problem:
      > cat main.cpp
      
      TEST(errnoTest, errnoTest)
      {
          ASSERT_EQ(errno, 0);
      }
      
      int main(int argc, char** argv)
      {
          ::testing::InitGoogleTest(&argc, argv);
      
          return RUN_ALL_TESTS();
      }
      
      Compiled with gcc 10 like this:
      > g++ -pthread -o runtest main.cpp -Wl,-Bstatic -lgtest -Wl,-Bdynamic
      
      Before patch:
      >  ./runtest
      [==========] Running 1 test from 1 test suite.
      [----------] Global test environment set-up.
      [----------] 1 test from errnoTest
      [ RUN      ] errnoTest.errnoTest
      [       OK ] errnoTest.errnoTest (0 ms)
      [----------] 1 test from errnoTest (0 ms total)
      
      [----------] Global test environment tear-down
      [==========] 1 test from 1 test suite ran. (0 ms total)
      [  PASSED  ] 1 test.
      
      (output is colored, I run this inside an interactive terminal).
      
      > ./runtest | cat
      [==========] Running 1 test from 1 test suite.
      [----------] Global test environment set-up.
      [----------] 1 test from errnoTest
      [ RUN      ] errnoTest.errnoTest
      main.cpp:5: Failure
      Expected equality of these values:
        (*__errno_location ())
          Which is: 25
        0
      [  FAILED  ] errnoTest.errnoTest (0 ms)
      [----------] 1 test from errnoTest (0 ms total)
      
      [----------] Global test environment tear-down
      [==========] 1 test from 1 test suite ran. (0 ms total)
      [  PASSED  ] 0 tests.
      [  FAILED  ] 1 test, listed below:
      [  FAILED  ] errnoTest.errnoTest
      
       1 FAILED TEST
      
      (output is not colored, since IsTTY return false, because of the pipe,
      however it also clobbered errno for the tests).
      
      After the patch, both cases are working fine:
      > ./runtest
      [==========] Running 1 test from 1 test suite.
      [----------] Global test environment set-up.
      [----------] 1 test from errnoTest
      [ RUN      ] errnoTest.errnoTest
      [       OK ] errnoTest.errnoTest (0 ms)
      [----------] 1 test from errnoTest (0 ms total)
      
      [----------] Global test environment tear-down
      [==========] 1 test from 1 test suite ran. (0 ms total)
      [  PASSED  ] 1 test.
      
      > ./runtest | cat
      [==========] Running 1 test from 1 test suite.
      [----------] Global test environment set-up.
      [----------] 1 test from errnoTest
      [ RUN      ] errnoTest.errnoTest
      [       OK ] errnoTest.errnoTest (0 ms)
      [----------] 1 test from errnoTest (0 ms total)
      
      [----------] Global test environment tear-down
      [==========] 1 test from 1 test suite ran. (0 ms total)
      [  PASSED  ] 1 test.
      a1b0173d
  13. 28 Feb, 2020 2 commits
    • Abseil Team's avatar
      Googletest export · e588eb1f
      Abseil Team authored
      Rename internal color enumerators to avoid conflicts with curses.h macro definitions.
      Fixes #2685
      
      PiperOrigin-RevId: 297639382
      e588eb1f
    • Abseil Team's avatar
      Googletest export · 909b1ccf
      Abseil Team authored
      Relax the implementation of MatcherCast to allow conversion of `Matcher<T>` to
      `Matcher<const T&>`. They have the same match signature.
      
      PiperOrigin-RevId: 297115843
      909b1ccf