GCC Code Coverage Report


Directory: ./
File: tasks/terekhov_d_fast_sort_batch/seq/src/ops_seq.cpp
Date: 2026-01-27 01:59:34
Exec Total Coverage
Lines: 13 13 100.0%
Functions: 5 5 100.0%
Branches: 6 8 75.0%

Line Branch Exec Source
1 #include "terekhov_d_fast_sort_batch/seq/include/ops_seq.hpp"
2
3 #include <algorithm>
4 #include <utility>
5 #include <vector>
6
7 #include "terekhov_d_fast_sort_batch/common/include/common.hpp"
8
9 namespace terekhov_d_fast_sort_batch {
10
11
1/2
✓ Branch 1 taken 210 times.
✗ Branch 2 not taken.
210 TerekhovDFastSortBatchSEQ::TerekhovDFastSortBatchSEQ(const InType &in) {
12 SetTypeOfTask(GetStaticTypeOfTask());
13
1/2
✓ Branch 1 taken 210 times.
✗ Branch 2 not taken.
210 GetInput() = in;
14 210 GetOutput() = std::vector<int>();
15 210 }
16
17 210 bool TerekhovDFastSortBatchSEQ::ValidationImpl() {
18 210 return GetOutput().empty();
19 }
20
21 210 bool TerekhovDFastSortBatchSEQ::PreProcessingImpl() {
22 210 return true;
23 }
24
25
2/2
✓ Branch 0 taken 202 times.
✓ Branch 1 taken 8 times.
210 bool TerekhovDFastSortBatchSEQ::RunImpl() {
26 const auto &input_data = GetInput();
27
2/2
✓ Branch 0 taken 202 times.
✓ Branch 1 taken 8 times.
210 if (input_data.empty()) {
28 return true;
29 }
30
31 202 std::vector<int> sorted_buffer = input_data;
32 std::ranges::sort(sorted_buffer);
33
34 GetOutput() = std::move(sorted_buffer);
35 return true;
36 }
37
38 210 bool TerekhovDFastSortBatchSEQ::PostProcessingImpl() {
39 210 return true;
40 }
41
42 } // namespace terekhov_d_fast_sort_batch
43