Skip to content

🐛 Fix std includes for GTest.h - #99

Merged
kris-jusiak merged 1 commit into
cpp-testing:masterfrom
elbeno:fix-std-includes
Dec 16, 2024
Merged

🐛 Fix std includes for GTest.h#99
kris-jusiak merged 1 commit into
cpp-testing:masterfrom
elbeno:fix-std-includes

Conversation

@elbeno

Copy link
Copy Markdown
Contributor

Problem:

  • GTest.h uses constructs from std:: without including them; in later versions of GoogleTest they are not necessarily transitively included.

Solution:

  • Add includes for:
    • iomanip (std::left, std::setw)
    • iostream (std::cout, std::endl)
    • tuple (std::tie)
    • type_traits (various e.g. std::is_same)

Problem:
- GTest.h uses constructs from `std::` without including them; in later versions
of GoogleTest they are not necessarily transitively included.
Solution:
- Add includes for:
- `iomanip` (`std::left`, `std::setw`)
- `iostream` (`std::cout`, `std::endl`)
- `tuple` (`std::tie`)
- `type_traits` (various e.g. `std::is_same`)
@kris-jusiak
kris-jusiak merged commit 467b07d into cpp-testing:masterDec 16, 2024
@kris-jusiak

Copy link
Copy Markdown
Contributor

Thanks @elbeno

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@elbeno@kris-jusiak