Commit f6e1b8d7aa234dd32fb8c835b27b09ff09e3d520
Committed by
Henry Schreiner
1 parent
8961df0e
Adding windows test
Showing
3 changed files
with
18 additions
and
1 deletions
tests/CMakeLists.txt
tests/WindowsTest.cpp
0 → 100644
| 1 | +#include "app_helper.hpp" | |
| 2 | +#include <Windows.h> | |
| 3 | + | |
| 4 | +// This test verifies that CLI11 still works if | |
| 5 | +// Windows.h is included. #145 | |
| 6 | + | |
| 7 | +TEST_F(TApp, WindowsTestSimple) { | |
| 8 | + app.add_flag("-c,--count"); | |
| 9 | + args = {"-c"}; | |
| 10 | + run(); | |
| 11 | + EXPECT_EQ((size_t)1, app.count("-c")); | |
| 12 | + EXPECT_EQ((size_t)1, app.count("--count")); | |
| 13 | +} | ... | ... |