summaryrefslogtreecommitdiffstats
path: root/googletest/include/gtest/internal/gtest-port.h
Commit message (Collapse)AuthorAgeFilesLines
* Googletest exportAbseil Team2020-02-111-0/+31
| | | | | | Add gmock Matcher<std::string_view> specialization. PiperOrigin-RevId: 294443240
* Make move operation noexcept.Piotr Paczkowski (trzeci.eu)2019-12-201-2/+2
|
* Review notes: Return T& from assignment operatorsPiotr Paczkowski (trzeci.eu)2019-12-201-2/+2
|
* Disable move constructor and assignment operator for test classes.trzeci2019-12-171-2/+15
| | | | | | | | | Disable move operations for TEST() and TEST_F() macros. Previous implementation disabled only copy ctor and assing operator, but this was violating rule of 5[1], which was captured by static code analysis tools like clang-tidy `cppcoreguidelines-special-member-functions`. [1]: https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md#c21-if-you-define-or-delete-any-default-operation-define-or-delete-them-all
* Googletest exportAbseil Team2019-11-261-1/+1
| | | | | | | | Wrap call to std::numeric_limits<>::max into round braces to appease MSVC. Closes #2589 PiperOrigin-RevId: 282581361
* Googletest exportAbseil Team2019-11-221-38/+21
| | | | | | | | | | | | | Use standard C++11 integer types in gtest-port.h. Remove testing::internal::{Int,Uint}{32,64} in favor of types guaranteed to be in <cstdint> since C++11. Tests for built-in integer type coverage are switched from {Int,Uint}64 to [unsigned] long long, which is guaranteed by C++11 to exist and be at least 64-bit wide. PiperOrigin-RevId: 281565263
* Merge pull request #2453 from kuzkry:gtest-port-clean-up_kMaxBiggestIntXiaoyi Zhang2019-11-041-0/+14
|\ | | | | | | PiperOrigin-RevId: 278008286
* \ Merge pull request #2453 from kuzkry:gtest-port-clean-up_kMaxBiggestIntvslashg2019-11-011-14/+0
|\ \ | |/ | | | | PiperOrigin-RevId: 277979766
| * remove BiggestIntrefs/pull/2453/headKrystian Kuzniarek2019-10-241-14/+0
| |
* | Merge pull request #2515 from ciband:feat/support_esp8266vslashg2019-10-251-4/+22
|\ \ | | | | | | | | | PiperOrigin-RevId: 276333426
| * \ feat: Add ESP8266 supportChris2019-10-141-3/+19
| |\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Added support for ESP8266 * Removed previous Arduino defines in favor of GTEST_OS_* syntax * Improved PlatformIO library file to be more stable when consumed in client applications.
| | * | Update to distinguish prelease purpose of this fork.Chris Johnson2019-10-111-5/+5
| | | |
| | * | Add ESP8266 configs to PlatformIO buildChris Johnson2019-10-111-0/+16
| |/ / | | | | | | | | | | | | Added various conditional compliations for ESP8266 to stub out missing functionality.
* | | Merge pull request #2444 from kuzkry:remove-GTEST_ARRAY_SIZE_Gennadiy Civil2019-10-221-3/+0
|\ \ \ | | | | | | | | | | | | PiperOrigin-RevId: 275842505
| * | | remove GTEST_ARRAY_SIZE_refs/pull/2444/headKrystian Kuzniarek2019-09-231-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This macro didn't work when an array was passed to a function by pointer, in which case the information about its size was lost. Better alternatives are: * std::extent<T>::value (compile-time) * std::array<T, N>::size() (compile-time) * std::distance(std::begin(array), std::end(array)) (run-time)
* | | | Googletest exportAbseil Team2019-10-221-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove bool_constant in favor of std::integral_constant<bool, ...>; The one non-trivial use of bool_constant has been changed to have significantly fewer template specializations. PiperOrigin-RevId: 275842490
* | | | Merge pull request #2454 from kuzkry:gtest-port-clean-up_dead-functionGennadiy Civil2019-10-221-11/+4
|\ \ \ \ | | | | | | | | | | | | | | | PiperOrigin-RevId: 275838743
| * | | | change includes in gtest-port.hrefs/pull/2454/headKrystian Kuzniarek2019-09-111-4/+1
| | | | |
| * | | | remove a dead functionKrystian Kuzniarek2019-09-101-4/+0
| | |_|/ | |/| |
* | | | Add more override keywordsrefs/pull/2507/headRobert Luberda2019-10-111-2/+2
| |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Mark more functions with "override" keyword, just like it was done in commit 2460f97152c. This should prevent compiler from complaining while compiling both user code, and the googletest code itself with the -Wsuggest-override option turned on; with the exception of: * calls to new MOCK_METHOD() in test/gmock-function-mocker_test.cc * calls to old MOCK_METHODx()/MOCK_CONST_METHODx() in other unit test files. Closes #2493
* | | Merge pull request #2456 from kuzkry:gtest-port-clean-up_breaking-changesGennadiy Civil2019-10-111-9/+0
|\ \ \ | | | | | | | | | | | | PiperOrigin-RevId: 274100752
| * | | remove GTEST_HAS_STD_STRINGrefs/pull/2456/headKrystian Kuzniarek2019-09-101-9/+0
| |/ /
* | | Add many missing override keywordsrefs/pull/2475/headPeter Barker2019-09-251-2/+2
| |/ |/| | | | | This helps corrects builds with -Werror=suggest-overrides
* | Googletest exportkuzkry2019-09-161-11/+0
| | | | | | | | | | | | | | | | | | Merge 3bdefdb473d304803d2a38e2a2cd5cdc1827c3bd into fb49e6c164490a227bbb7cf5223b846c836a0305 Closes #2407 COPYBARA_INTEGRATE_REVIEW=https://github.com/google/googletest/pull/2407 from kuzkry:StaticAssertTypeEq 3bdefdb473d304803d2a38e2a2cd5cdc1827c3bd PiperOrigin-RevId: 269255328
* | Merge pull request #2387 from kuzkry:iffShaindel Schwartz2019-09-121-17/+22
|\ \ | |/ |/| | | PiperOrigin-RevId: 268693457
| * restore mistakenly removed iffs in their explicit formrefs/pull/2387/headKrystian Kuzniarek2019-08-201-17/+22
| | | | | | | | | | Due to confusion arisen from "iff" standing for "if and only if", this commit uses the latter.
* | Merge pull request #2398 from kuzkry:custom-type-traits-iterator_traitsGennadiy Civil2019-08-291-21/+0
|\ \ | | | | | | | | | PiperOrigin-RevId: 266136896
| * | remove a custom implementation of std::iterator_traitsKrystian Kuzniarek2019-08-131-21/+0
| | |
* | | Googletest exportkuzkry2019-08-231-9/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | Merge b8ca465e73ac0954a0c9eec2a84bdd8913d5763b into 90a443f9c2437ca8a682a1ac625eba64e1d74a8a Closes #2396 COPYBARA_INTEGRATE_REVIEW=https://github.com/google/googletest/pull/2396 from kuzkry:custom-type-traits-true/false_type-and-bool_constant b8ca465e73ac0954a0c9eec2a84bdd8913d5763b PiperOrigin-RevId: 265064856
* | | Merge pull request #2401 from kuzkry:custom-type-traits-add_lvalue_referenceXiaoyi Zhang2019-08-231-13/+0
|\ \ \ | |_|/ |/| | | | | PiperOrigin-RevId: 264842713
| * | remove a custom implementation of std::add_lvalue_referencerefs/pull/2401/headKrystian Kuzniarek2019-08-131-13/+0
| |/
* | remove custom implementations of std::is_samerefs/pull/2399/headKrystian Kuzniarek2019-08-141-16/+0
|/
* fix typosrefs/pull/2356/headKrystian Kuzniarek2019-07-301-12/+12
|
* Sort Haiku platform definition alphabetically.refs/pull/2230/headCalvin Hill2019-04-121-2/+2
| | | | | Fixes a minor ordering issue when defining the platform macro. Also fixes a minor typo: 'Max OS X' -> 'Mac OS X'.
* Merge pull request #2229 from return:haiku-supportGennadiy Civil2019-04-111-12/+14
|\ | | | | | | PiperOrigin-RevId: 243104604
| * Add Haiku platform support.refs/pull/2229/headCalvin Hill2019-04-111-3/+5
|/ | | | | This allows googletest to recognize the Haiku operating system when running tests in other projects.
* Googletest exportAbseil Team2019-04-011-0/+12
| | | | | | | | | | | | | | | Add HWASan annotations. These mirror existing ASan annotations. HWASan uses memory (address) tagging to detect memory errors: https://clang.llvm.org/docs/HardwareAssistedAddressSanitizerDesign.html It inserts a random tag in the MSB of heap and stack allocation addresses. This tag dominates pointer comparison in StackGrowsDown(), making the result non-deterministic, and entirely unrelated to the actual stack growth direction. The function attribute disables this behavior. The annotations in gtest-printers are there because the printers are used to basically dump memory. The sanitizers may have ideas why this memory should not be accessed, and that is counter productive. In particular, the test may access only part of an array, but in case of a test failure gtest will dump the entire array which may contain uninitialized bytes - that's what SANITIZE_MEMORY annotation is for. There are similar reasons for ADDRESS and THREAD annotations. HWADDRESS in its current implementation can not cause issues there, I believe, but it falls under the same umbrella of tools whose checking should not apply to test printers because it is not the code under test. PiperOrigin-RevId: 241379822
* Googletest exportAbseil Team2019-04-011-50/+1
| | | | | | | | Remove support for "global" ::string and ::wstring types. This support existed for legacy codebases that existed from before namespaces where a thing. It is no longer necessary. PiperOrigin-RevId: 241335738
* Googletest exportAbseil Team2019-03-011-0/+9
| | | | | | | | | | | | | | Let embedders customize GTEST_INTERNAL_DEPRECATED(). GTEST_INTERNAL_DEPRECATED is currently used to nudge googletest users to migrate off old TEST_CASE macros to the new TEST_SUITE macros. This move is non-trivial for Chromium (see https://crbug.com/925652), and might be difficult for other big projects with many dependencies. This CL facilitates moving off of deprecated APIs by making it possible for an embedder to define GTEST_INTERNAL_DEPRECATED() in gtest/internal/custom/gtest-port.h. Example usage: 1) #define GTEST_INTERNAL_DEPRECATED() to nothing, to disable deprecation warnings while migrating off googletest's deprecated APIs. This can be preferable to having to disable all deprecation warnings (-Wno-error=deprecated or -Wno-deprecated-declarations). 2) #define GTEST_INTERNAL_DEPRECATED() for an unsupported compiler. PiperOrigin-RevId: 236171043
* Import `patch-bsd-defines` from FreeBSD ports [1]Enji Cooper2019-02-131-3/+8
| | | | | | | | | | As noted in the patch description: * Add DragonFly and GNU/kFreeBSD support. * Implement GetThreadCount() for BSDs. 1. https://svnweb.freebsd.org/ports/head/devel/googletest/files/patch-bsd-defines?revision=488934 Signed-off-by: Enji Cooper <yaneurabeya@gmail.com>
* Googletest exportmisterg2019-02-041-0/+16
| | | | | | Mark legacy _TEST_CASE_ macros as deprecated PiperOrigin-RevId: 232303251
* Googletest exportmisterg2019-01-031-0/+1
| | | | | | TestCase->TestSuite refactoring PiperOrigin-RevId: 227702164
* Googletest exportmisterg2019-01-021-13/+0
| | | | | | Internal Change PiperOrigin-RevId: 227575279
* Googletest exportAbseil Team2019-01-021-41/+6
| | | | | | | | Remove the #ifs for old, unsupported and buggy compilers: * old versions of GCC & MSVC * Symbian PiperOrigin-RevId: 227116941
* Googletest exportAbseil Team2018-12-201-113/+8
| | | | | | Unifdef c++11-related macros from googletest now that it requires C++11. PiperOrigin-RevId: 225905601
* Googletest exportmisterg2018-12-131-1/+1
| | | | | | Internal Change PiperOrigin-RevId: 225231727
* Merge pull request #1997 from gpakosz:GTEST_IS_THREADSAFEGennadiy Civil2018-12-051-5/+9
|\ | | | | | | PiperOrigin-RevId: 224054240
| * Do not define GTEST_IS_THREADSAFE within GTEST_HAS_SEHrefs/pull/1997/headGregory Pakosz2018-12-041-5/+9
|/
* Googletest exportAbseil Team2018-12-031-2/+2
| | | | | | Applied fixes for ClangTidy modernize-use-override and modernize-use-using. PiperOrigin-RevId: 223800219
* Googletest exportmisterg2018-11-201-1/+1
| | | | | | Internal Change PiperOrigin-RevId: 222123106