xref: /openbmc/phosphor-ipmi-blobs/test/manager_getsession_unittest.cpp (revision cd8dab491d3f78124be800252186a32a90c884b8)
1 #include "manager.hpp"
2 
3 #include <gtest/gtest.h>
4 
5 namespace blobs
6 {
7 
TEST(ManagerGetSessionTest,NextSessionReturned)8 TEST(ManagerGetSessionTest, NextSessionReturned)
9 {
10     // This test verifies the next session ID is returned.
11     BlobManager mgr;
12 
13     uint16_t first, second;
14     EXPECT_TRUE(mgr.getSession(&first));
15     EXPECT_TRUE(mgr.getSession(&second));
16     EXPECT_FALSE(first == second);
17 }
18 
TEST(ManagerGetSessionTest,SessionsCheckedAgainstList)19 TEST(ManagerGetSessionTest, SessionsCheckedAgainstList)
20 {
21     // TODO(venture): Need a test that verifies the session ids are checked
22     // against open sessions.
23 }
24 } // namespace blobs
25