| 18 | #include <algorithm> |
| 19 | |
| 20 | void string_equal(std::string str1, std::string str2) { |
| 21 | auto is_space = [](char c) { |
| 22 | return c == ' '; |
| 23 | }; // *only* space, opposed to builtin isspace |
| 24 | auto it = std::remove_if(str1.begin(), str1.end(), is_space); |
| 25 | str1 = std::string(str1.begin(), it); |
| 26 | it = std::remove_if(str2.begin(), str2.end(), is_space); |
| 27 | str2 = std::string(str2.begin(), it); |
| 28 | EXPECT_EQ(str1, str2); |
| 29 | } |
| 30 | |
| 31 | TEST(Tensor, initialization) { |
| 32 | { |