Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Limit bz1 quickcheck tests to 10 iterations on CI #3950

Merged
merged 1 commit into from
Sep 2, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ With this release InfluxDB is moving to Go 1.5.
- [#3927](https://github.com/influxdb/influxdb/issues/3927): Add WAL lock to prevent timing lock contention
- [#3928](https://github.com/influxdb/influxdb/issues/3928): Write fails for multiple points when tag starts with quote
- [#3901](https://github.com/influxdb/influxdb/pull/3901): Unblock relaxed write consistency level Thanks @takayuki!
- [#3950](https://github.com/influxdb/influxdb/pull/3950): Limit bz1 quickcheck tests to 10 iterations on CI

## v0.9.3 [2015-08-26]

Expand Down
15 changes: 13 additions & 2 deletions tsdb/engine/bz1/bz1_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import (
"bytes"
"encoding/binary"
"errors"
"fmt"
"io/ioutil"
"math/rand"
"os"
Expand All @@ -21,6 +22,16 @@ import (
"github.com/influxdb/influxdb/tsdb/engine/wal"
)

var QuickConfig quick.Config

func init() {
// Limit the number of iterations on CI so it doesn't take so long.
if os.Getenv("CI") == "true" {
QuickConfig.MaxCount = 10
fmt.Fprintf(os.Stderr, "Limiting quickchecks to %d iterations (CI)\n", QuickConfig.MaxCount)
}
}

// Ensure the engine can write series metadata and reload it.
func TestEngine_LoadMetadataIndex_Series(t *testing.T) {
e := OpenDefaultEngine()
Expand Down Expand Up @@ -337,7 +348,7 @@ func TestEngine_WriteIndex_Quick(t *testing.T) {
}

return true
}, nil)
}, &QuickConfig)
}

// Ensure the engine can accept randomly generated append-only points.
Expand Down Expand Up @@ -384,7 +395,7 @@ func TestEngine_WriteIndex_Quick_Append(t *testing.T) {
}

return true
}, nil)
}, &QuickConfig)
}

func BenchmarkEngine_WriteIndex_512b(b *testing.B) { benchmarkEngine_WriteIndex(b, 512) }
Expand Down