RpcSessionTest.cc 752 B

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. #include <boost/asio.hpp>
  2. #include <gtest/gtest.h>
  3. #include <glog/logging.h>
  4. #include <gflags/gflags.h>
  5. #include "Rpc/RpcSession.h"
  6. #include "Rpc/RpcServerMock.h"
  7. namespace Egametang {
  8. class RpcSessionTest: public testing::Test
  9. {
  10. protected:
  11. boost::asio::io_service ioService;
  12. int port;
  13. RpcServerMock mockServer;
  14. RpcSession session;
  15. public:
  16. RpcSessionTest():
  17. ioService(), port(10000),
  18. mockServer(ioService, port), session(ioService, mockServer)
  19. {
  20. }
  21. virtual ~RpcSessionTest()
  22. {
  23. }
  24. };
  25. TEST_F(RpcSessionTest, Test1)
  26. {
  27. }
  28. } // namespace Egametang
  29. int main(int argc, char* argv[])
  30. {
  31. testing::InitGoogleTest(&argc, argv);
  32. google::InitGoogleLogging(argv[0]);
  33. google::ParseCommandLineFlags(&argc, &argv, true);
  34. return RUN_ALL_TESTS();
  35. }