File tree Expand file tree Collapse file tree
modules/core/task/func_tests Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -178,6 +178,24 @@ TEST(task_tests, check_wrong_order) {
178178 ASSERT_ANY_THROW (test_task.PostProcessing ());
179179}
180180
181+ TEST (task_tests, terminates_on_wrong_order_no_calls) {
182+ // Create data
183+ std::vector<float > in (20 , 1 );
184+ std::vector<float > out (1 , 0 );
185+
186+ // Create task_data
187+ auto task_data = std::make_shared<ppc::core::TaskData>();
188+ task_data->inputs .emplace_back (reinterpret_cast <uint8_t *>(in.data ()));
189+ task_data->inputs_count .emplace_back (in.size ());
190+ task_data->outputs .emplace_back (reinterpret_cast <uint8_t *>(out.data ()));
191+ task_data->outputs_count .emplace_back (out.size ());
192+ ASSERT_DEATH ({
193+ // Create Task
194+ ppc::test::task::TestTask<float > test_task (task_data);
195+ // dtor throws std::terminate
196+ }, " ORDER OF FUNCTIONS IS NOT RIGHT" );
197+ }
198+
181199int main (int argc, char **argv) {
182200 testing::InitGoogleTest (&argc, argv);
183201 return RUN_ALL_TESTS ();
You can’t perform that action at this time.
0 commit comments