Updated tests to align with new sequence memory management workflow

This commit is contained in:
Alejandro Saucedo 2020-11-01 20:25:53 +00:00
parent 473031d1f3
commit e2f6e876bc
4 changed files with 54 additions and 46 deletions

View file

@ -32,14 +32,14 @@ TEST(TestLogisticRegressionAlgorithm, TestMainLogisticRegression)
kp::Manager mgr;
std::shared_ptr<kp::Sequence> sqTensor =
mgr.createManagedSequence().lock();
mgr.createManagedSequence();
sqTensor->begin();
sqTensor->record<kp::OpTensorCreate>(params);
sqTensor->end();
sqTensor->eval();
std::shared_ptr<kp::Sequence> sq = mgr.createManagedSequence().lock();
std::shared_ptr<kp::Sequence> sq = mgr.createManagedSequence();
// Record op algo base
sq->begin();
@ -115,14 +115,14 @@ TEST(TestLogisticRegressionAlgorithm, TestMainLogisticRegressionManualCopy)
kp::Manager mgr;
std::shared_ptr<kp::Sequence> sqTensor =
mgr.createManagedSequence().lock();
mgr.createManagedSequence();
sqTensor->begin();
sqTensor->record<kp::OpTensorCreate>(params);
sqTensor->end();
sqTensor->eval();
std::shared_ptr<kp::Sequence> sq = mgr.createManagedSequence().lock();
std::shared_ptr<kp::Sequence> sq = mgr.createManagedSequence();
// Record op algo base
sq->begin();