GCC Code Coverage Report


Directory: ./
File: tasks/lukin_i_elem_vec_sum/seq/src/ops_seq.cpp
Date: 2025-12-13 04:24:21
Exec Total Coverage
Lines: 14 14 100.0%
Functions: 5 5 100.0%
Branches: 2 4 50.0%

Line Branch Exec Source
1 #include "lukin_i_elem_vec_sum/seq/include/ops_seq.hpp"
2
3 #include <numeric>
4 #include <vector>
5
6 #include "lukin_i_elem_vec_sum/common/include/common.hpp"
7
8 namespace lukin_i_elem_vec_sum {
9
10
1/2
✓ Branch 1 taken 88 times.
✗ Branch 2 not taken.
88 LukinIElemVecSumSEQ::LukinIElemVecSumSEQ(const InType &in) {
11 SetTypeOfTask(GetStaticTypeOfTask());
12
1/2
✓ Branch 1 taken 88 times.
✗ Branch 2 not taken.
88 GetInput() = in;
13 88 GetOutput() = 0;
14 88 }
15
16 88 bool LukinIElemVecSumSEQ::ValidationImpl() {
17 88 return (static_cast<int>(GetInput().size()) != 0);
18 }
19
20 88 bool LukinIElemVecSumSEQ::PreProcessingImpl() {
21 88 vec_size_ = static_cast<int>(GetInput().size());
22 88 return true;
23 }
24
25 88 bool LukinIElemVecSumSEQ::RunImpl() {
26 OutType sum = std::accumulate(GetInput().begin(), GetInput().end(), 0LL);
27
28 88 GetOutput() = sum;
29 88 return true;
30 }
31
32 88 bool LukinIElemVecSumSEQ::PostProcessingImpl() {
33 88 return true;
34 }
35
36 } // namespace lukin_i_elem_vec_sum
37