Commit 70b2c190 authored by Nicolas Carion's avatar Nicolas Carion

fix tests

parent 90b937aa
......@@ -263,6 +263,7 @@ void Logger::print_trace()
test_file << "auto binModel = pCore->projectItemModel();" << std::endl;
test_file << "std::shared_ptr<DocUndoStack> undoStack = std::make_shared<DocUndoStack>(nullptr);" << std::endl;
test_file << "std::shared_ptr<MarkerListModel> guideModel = std::make_shared<MarkerListModel>(undoStack);" << std::endl;
test_file << "TimelineModel::next_id = 0;" << std::endl;
test_file << "{" << std::endl;
test_file << "Mock<ProjectManager> pmMock;" << std::endl;
test_file << "When(Method(pmMock, undoStack)).AlwaysReturn(undoStack);" << std::endl;
......@@ -354,7 +355,6 @@ void Logger::print_trace()
}
test_file << "}" << std::endl;
test_file << "pCore->m_projectManager = nullptr;" << std::endl;
test_file << "Core::m_self.reset();" << std::endl;
test_file << "}" << std::endl;
}
void Logger::clear()
......
......@@ -419,6 +419,7 @@ TEST_CASE("FuzzBug1")
auto binModel = pCore->projectItemModel();
std::shared_ptr<DocUndoStack> undoStack = std::make_shared<DocUndoStack>(nullptr);
std::shared_ptr<MarkerListModel> guideModel = std::make_shared<MarkerListModel>(undoStack);
TimelineModel::next_id = 0;
{
Mock<ProjectManager> pmMock;
When(Method(pmMock, undoStack)).AlwaysReturn(undoStack);
......@@ -549,5 +550,4 @@ TEST_CASE("FuzzBug1")
REQUIRE(timeline_0->checkConsistency());
}
pCore->m_projectManager = nullptr;
Core::m_self.reset();
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment