Exemplo n.º 1
0
func BenchmarkTidbNoCacheFindPtr(t *testing.B) {
	t.StopTimer()
	engine, err := newTidbEngine()
	if err != nil {
		t.Error(err)
		return
	}
	defer engine.Close()
	//engine.ShowSQL = true
	tests.DoBenchFindPtr(engine, t)
}
Exemplo n.º 2
0
func BenchmarkTidbCacheFindPtr(t *testing.B) {
	t.StopTimer()
	engine, err := newTidbEngine()
	if err != nil {
		t.Error(err)
		return
	}
	defer engine.Close()

	engine.SetDefaultCacher(newCache())
	tests.DoBenchFindPtr(engine, t)
}