Updated sequence and sequence tests
This commit is contained in:
parent
f206c62537
commit
9788c796a8
2 changed files with 17 additions and 39 deletions
|
|
@ -174,7 +174,7 @@ Sequence::destroy()
|
|||
KP_LOG_DEBUG("Kompute Sequence destroy called");
|
||||
|
||||
if (!this->mDevice) {
|
||||
KP_LOG_ERROR("Kompute Sequence destroy called "
|
||||
KP_LOG_WARN("Kompute Sequence destroy called "
|
||||
"with null Device pointer");
|
||||
return;
|
||||
}
|
||||
|
|
@ -182,7 +182,7 @@ Sequence::destroy()
|
|||
if (this->mFreeCommandBuffer) {
|
||||
KP_LOG_INFO("Freeing CommandBuffer");
|
||||
if (!this->mCommandBuffer) {
|
||||
KP_LOG_ERROR(
|
||||
KP_LOG_WARN(
|
||||
"Kompute Sequence destroy called with null "
|
||||
"CommandPool pointer");
|
||||
return;
|
||||
|
|
@ -199,7 +199,7 @@ Sequence::destroy()
|
|||
if (this->mFreeCommandPool) {
|
||||
KP_LOG_INFO("Destroying CommandPool");
|
||||
if (this->mCommandPool == nullptr) {
|
||||
KP_LOG_ERROR(
|
||||
KP_LOG_WARN(
|
||||
"Kompute Sequence destroy called with null "
|
||||
"CommandPool pointer");
|
||||
return;
|
||||
|
|
|
|||
|
|
@ -3,40 +3,18 @@
|
|||
|
||||
#include "kompute/Kompute.hpp"
|
||||
|
||||
//TEST(TestSequence, CmdBufSequenceBeginEnd)
|
||||
//{
|
||||
// kp::Manager mgr;
|
||||
//
|
||||
// {
|
||||
// std::shared_ptr<kp::Sequence> sq =
|
||||
// mgr.sequence("newSequence");
|
||||
//
|
||||
// EXPECT_TRUE(sq->eval());
|
||||
// EXPECT_TRUE(!sq->isRecording());
|
||||
// EXPECT_TRUE(sq->begin());
|
||||
// EXPECT_TRUE(sq->isRecording());
|
||||
// EXPECT_TRUE(!sq->begin());
|
||||
// EXPECT_TRUE(sq->isRecording());
|
||||
// EXPECT_TRUE(sq->end());
|
||||
// EXPECT_TRUE(!sq->isRecording());
|
||||
// EXPECT_TRUE(!sq->end());
|
||||
// EXPECT_TRUE(!sq->isRecording());
|
||||
// EXPECT_TRUE(sq->eval());
|
||||
// }
|
||||
//}
|
||||
//
|
||||
//TEST(TestSequence, SequenceDestructorViaManager)
|
||||
//{
|
||||
// std::shared_ptr<kp::Sequence> sq = nullptr;
|
||||
//
|
||||
// {
|
||||
// kp::Manager mgr;
|
||||
//
|
||||
// sq = mgr.sequence("newSequence");
|
||||
//
|
||||
// EXPECT_TRUE(sq->isInit());
|
||||
// }
|
||||
//
|
||||
// EXPECT_FALSE(sq->isInit());
|
||||
//}
|
||||
TEST(TestSequence, SequenceDestructorViaManager)
|
||||
{
|
||||
std::shared_ptr<kp::Sequence> sq = nullptr;
|
||||
|
||||
{
|
||||
kp::Manager mgr;
|
||||
|
||||
sq = mgr.sequence();
|
||||
|
||||
EXPECT_TRUE(sq->isInit());
|
||||
}
|
||||
|
||||
EXPECT_FALSE(sq->isInit());
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue