diff --git a/env/env_test.go b/env/env_test.go index a1da45f408ee5a423f3754f63e54ea7ed7476268..fa3805a252ef4714ad5ffc4121fa4b4e4c8b9d67 100644 --- a/env/env_test.go +++ b/env/env_test.go @@ -282,60 +282,3 @@ func TestCreateDatabase(t *testing.T) { } common.Log.Debug("Exiting function: %s", common.GetFunctionName()) } - -func TestCreateTable(t *testing.T) { - orgSamplingCondition := common.Config.SamplingCondition - common.Config.SamplingCondition = "LIMIT 1" - - vEnv, rEnv := BuildEnv() - defer vEnv.CleanUp() - // TODO: support VIEW, - tables := []string{ - "actor", - // "actor_info", // VIEW - "address", - "category", - "city", - "country", - "customer", - "customer_list", - "film", - "film_actor", - "film_category", - "film_list", - "film_text", - "inventory", - "language", - "nicer_but_slower_film_list", - "payment", - "rental", - // "sales_by_film_category", // VIEW - // "sales_by_store", // VIEW - "staff", - "staff_list", - "store", - } - for _, table := range tables { - err := vEnv.createTable(rEnv, "sakila", table) - if err != nil { - t.Error(err) - } - } - common.Config.SamplingCondition = orgSamplingCondition -} - -func TestCreateDatabase(t *testing.T) { - vEnv, rEnv := BuildEnv() - defer vEnv.CleanUp() - err := vEnv.createDatabase(rEnv, "sakila") - if err != nil { - t.Error(err) - } - if vEnv.DBHash("sakila") == "sakila" { - t.Errorf("database: sakila rehashed failed!") - } - - if vEnv.DBHash("not_exist_db") != "not_exist_db" { - t.Errorf("database: not_exist_db rehashed!") - } -}