class BindManagerTestBase
Defined at line 140 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.h
Public Methods
void SetUp ()
Defined at line 103 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void TearDown ()
Defined at line 120 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
BindManagerData CurrentBindManagerData ()
Defined at line 125 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void VerifyBindManagerData (BindManagerData expected)
Defined at line 134 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
driver_manager::NodeManager * GetNodeManager ()
Defined at line 152 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.h
void AddAndOrphanNode (std::string name, bool enable_multibind, std::shared_ptr<driver_manager::BindResultTracker> tracker)
Creates a node and adds it to orphaned nodes by invoking bind with a failed match.
Should only be called when there's no ongoing bind. The node should not
already exist.
Defined at line 168 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void AddAndBindNode (std::string name, bool enable_multibind, std::shared_ptr<driver_manager::BindResultTracker> tracker)
Create a node and invoke Bind() for it.
If EXPECT_BIND_START, the function verifies that it started a new bind process.
If EXPECT_QUEUED, the function verifies that it queued new bind request.
Defined at line 149 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void AddAndBindNode_EXPECT_BIND_START (std::string name, bool enable_multibind, std::shared_ptr<driver_manager::BindResultTracker> tracker)
Defined at line 213 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void AddAndBindNode_EXPECT_QUEUED (std::string name, bool enable_multibind, std::shared_ptr<driver_manager::BindResultTracker> tracker)
Defined at line 222 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void InvokeBind (std::string name, std::shared_ptr<driver_manager::BindResultTracker> tracker)
Invoke Bind() for the node with the given |name|. The node should already exist.
If EXPECT_BIND_START, the function verifies that it started a new bind process.
If EXPECT_QUEUED, the function verifies that it queued new bind request.
Defined at line 187 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void InvokeBind_EXPECT_BIND_START (std::string name, std::shared_ptr<driver_manager::BindResultTracker> tracker)
Defined at line 198 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void InvokeBind_EXPECT_QUEUED (std::string name, std::shared_ptr<driver_manager::BindResultTracker> tracker)
Defined at line 205 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
TestBindManager * bind_manager ()
Defined at line 220 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.h
void AddCompositeNodeSpec (std::string composite, std::vector<std::string> parents)
Defined at line 236 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void AddCompositeNodeSpec_EXPECT_BIND_START (std::string composite, std::vector<std::string> parents)
Defined at line 260 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void AddCompositeNodeSpec_EXPECT_QUEUED (std::string composite, std::vector<std::string> parents)
Defined at line 267 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void InvokeTryBindAllAvailable ()
Invoke TryBindAllAvailable().
If EXPECT_BIND_START, the function verifies that it started a new bind process.
If EXPECT_QUEUED, the function verifies that it queues a TryBindAllAvailable callback.
Defined at line 276 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void InvokeTryBindAllAvailable_EXPECT_BIND_START ()
Defined at line 281 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void InvokeTryBindAllAvailable_EXPECT_QUEUED ()
Defined at line 287 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void DriverIndexReplyWithDriver (std::string node)
Invoke DriverIndex reply for a match request for |node|.
Defined at line 298 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void DriverIndexReplyWithComposite (std::string node, std::vector<std::pair<std::string, size_t>> specs)
Defined at line 306 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void DriverIndexReplyWithNoMatch (std::string node)
Defined at line 324 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void VerifyNoOngoingBind ()
Defined at line 330 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void VerifyNoQueuedBind ()
Defined at line 336 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void VerifyBindOngoingWithRequests (std::vector<std::pair<std::string, size_t>> expected_requests)
Verifies that there's a ongoing bind process with an expected list of requests.
Each pair in |expected_requests| contains the node name and expected number of match requests.
Defined at line 357 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void VerifyOrphanedNodes (std::vector<std::string> expected_nodes)
Verify that the orphaned nodes set in BindManager contains |expected_nodes|.
Defined at line 341 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void VerifyMultibindNodes (std::vector<std::string> expected_nodes)
Verify that multibind nodes set in BindManager contains |expected_nodes|.
Defined at line 349 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void VerifyCompositeNodeExists (bool expected, std::string spec_name)
Defined at line 372 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
void VerifyPendingBindRequestCount (size_t expected)
Defined at line 368 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.cc
Protected Methods
std::unordered_map<std::string, std::shared_ptr<driver_manager::Node>> nodes ()
Defined at line 223 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.h
std::unordered_map<std::string, uint32_t> instance_ids ()
Defined at line 226 of file ../../src/devices/bin/driver_manager/tests/bind_manager_test_base.h