diff --git a/test/c++/itertools.cpp b/test/c++/itertools.cpp index 3b093c1..5438aec 100644 --- a/test/c++/itertools.cpp +++ b/test/c++/itertools.cpp @@ -201,6 +201,12 @@ TEST(Itertools, Product_Range) { EXPECT_EQ(res, 1000); } +TEST(Itertools, Stride) { + std::vector V1{0, 1, 2, 3, 4}; + int i = 0; + for (auto x : stride(V1, 1)) EXPECT_EQ(i++, x); +} + int main(int argc, char **argv) { ::testing::InitGoogleTest(&argc, argv); return RUN_ALL_TESTS();