Add more tests (#1949)

* add more test code

* add more test code
This commit is contained in:
zryfish
2020-03-15 10:22:39 +08:00
committed by GitHub
parent f8e7d06b07
commit abf0d66b22
13 changed files with 444 additions and 55 deletions

View File

@@ -188,6 +188,7 @@ func (conf *Config) toMap() map[string]bool {
return result
}
// Remove invalid options before serializing to json or yaml
func (conf *Config) stripEmptyOptions() {
if conf.MySQLOptions != nil && conf.MySQLOptions.Host == "" {
conf.MySQLOptions = nil