Skip to content

Commit 1616c0f

Browse files
committed
Problem: test file not correctly named
Solution: move and split example_add.cpp
1 parent 80dc604 commit 1616c0f

File tree

3 files changed

+11
-7
lines changed

3 files changed

+11
-7
lines changed

tests/CMakeLists.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,8 @@ fetch_googletest(
2222

2323
add_executable(
2424
unit_tests
25-
example_add.cpp
25+
context.cpp
26+
socket.cpp
2627
)
2728

2829
target_link_libraries(

tests/example_add.cpp renamed to tests/context.cpp

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,3 @@ TEST(context, create_close)
1313

1414
ASSERT_EQ(NULL, (void*)context);
1515
}
16-
17-
TEST(socket, create_destroy)
18-
{
19-
zmq::context_t context;
20-
zmq::socket_t socket(context, ZMQ_ROUTER);
21-
}

tests/socket.cpp

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
#include <gtest/gtest.h>
2+
#include <zmq.hpp>
3+
4+
TEST(socket, create_destroy)
5+
{
6+
zmq::context_t context;
7+
zmq::socket_t socket(context, ZMQ_ROUTER);
8+
}
9+

0 commit comments

Comments
 (0)