(t *testing.T, step time.Duration, from model.Time, points int, enc encoding.Encoding)
| 2971 | } |
| 2972 | |
| 2973 | func createAggrChunk(t *testing.T, step time.Duration, from model.Time, points int, enc encoding.Encoding) storepb.AggrChunk { |
| 2974 | c := util.GenerateChunk(t, step, from, points, enc) |
| 2975 | chunkType := storepb.Chunk_XOR |
| 2976 | switch enc { |
| 2977 | case encoding.PrometheusHistogramChunk: |
| 2978 | chunkType = storepb.Chunk_HISTOGRAM |
| 2979 | case encoding.PrometheusFloatHistogramChunk: |
| 2980 | chunkType = storepb.Chunk_FLOAT_HISTOGRAM |
| 2981 | default: |
| 2982 | } |
| 2983 | return storepb.AggrChunk{ |
| 2984 | MinTime: int64(c.From), |
| 2985 | MaxTime: int64(c.Through), |
| 2986 | Raw: &storepb.Chunk{ |
| 2987 | Type: chunkType, |
| 2988 | Data: c.Data.Bytes(), |
| 2989 | }, |
| 2990 | } |
| 2991 | } |
no test coverage detected