summaryrefslogtreecommitdiffstats
path: root/test/manager_getsession_unittest.cpp
blob: e66729a7797ce0ef014936c1d4e68952c7421aaa (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#include "manager.hpp"

#include <gtest/gtest.h>

namespace blobs
{

TEST(ManagerGetSessionTest, NextSessionReturned)
{
    // This test verifies the next session ID is returned.
    BlobManager mgr;

    uint16_t first, second;
    EXPECT_TRUE(mgr.getSession(&first));
    EXPECT_TRUE(mgr.getSession(&second));
    EXPECT_FALSE(first == second);
}

TEST(ManagerGetSessionTest, SessionsCheckedAgainstList)
{
    // TODO(venture): Need a test that verifies the session ids are checked
    // against open sessions.
}
} // namespace blobs
OpenPOWER on IntegriCloud