This commit is contained in:
2026-06-13 07:13:03 +00:00
parent aca0252cfd
commit 5778782737
10 changed files with 99 additions and 58 deletions

View File

@@ -623,7 +623,6 @@ func TestMeasuresAppendRecord(t *testing.T) {
func TestMeasuresAppendWithGrowRecord(t *testing.T) {
DataPageSize = 8
IndexPageSize = 4
indexRecordSize = 2
//
rec := MeasuresAppendWithGrowRecord{
MetricID: 12345,
@@ -735,8 +734,7 @@ func TestWritePreparer(t *testing.T) {
prevPageIdx = DataPageSize - 12
// index page
IndexPageSize = 16
indexRecordSize = 4 // 2 records per index page
IndexPageSize = 24
maxRecordsOnIndexPage = 2
indexCRC32Idx = IndexPageSize - 4
indexRecordsCountIdx = IndexPageSize - 6
@@ -835,9 +833,9 @@ func TestWritePreparer(t *testing.T) {
IndexLevelTails: []IndexLevelTail{
{
Buffer: []byte{
0x01, 0x01, // since
0x0a, 0x00, // pageNo 10
0x00, 0x00, 0x00, 0x00, 0x00, // empty space
0x01, 0x01, 0x00, 0x00, // since
0x0a, 0x00, 0x00, 0x00, // pageNo 10
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // empty space
0x00, // zero level
0x00, 0x00, // records count
0x00, 0x00, 0x00, 0x00, // crc32