| 1100 | namespace { |
| 1101 | |
| 1102 | BatchesWithSchema MakeGroupableBatches(int multiplicity = 1) { |
| 1103 | BatchesWithSchema out; |
| 1104 | |
| 1105 | out.batches = {ExecBatchFromJSON({int32(), utf8()}, R"([ |
| 1106 | [12, "alfa"], |
| 1107 | [7, "beta"], |
| 1108 | [3, "alfa"] |
| 1109 | ])"), |
| 1110 | ExecBatchFromJSON({int32(), utf8()}, R"([ |
| 1111 | [-2, "alfa"], |
| 1112 | [-1, "gama"], |
| 1113 | [3, "alfa"] |
| 1114 | ])"), |
| 1115 | ExecBatchFromJSON({int32(), utf8()}, R"([ |
| 1116 | [5, "gama"], |
| 1117 | [3, "beta"], |
| 1118 | [-8, "alfa"] |
| 1119 | ])")}; |
| 1120 | |
| 1121 | size_t batch_count = out.batches.size(); |
| 1122 | for (int repeat = 1; repeat < multiplicity; ++repeat) { |
| 1123 | for (size_t i = 0; i < batch_count; ++i) { |
| 1124 | out.batches.push_back(out.batches[i]); |
| 1125 | } |
| 1126 | } |
| 1127 | |
| 1128 | out.schema = schema({field("i32", int32()), field("str", utf8())}); |
| 1129 | |
| 1130 | return out; |
| 1131 | } |
| 1132 | |
| 1133 | } // namespace |
| 1134 | |