diff --git a/src/go/pt-galera-log-explainer/main_test.go b/src/go/pt-galera-log-explainer/main_test.go index da2ba0dbd..a2e933008 100644 --- a/src/go/pt-galera-log-explainer/main_test.go +++ b/src/go/pt-galera-log-explainer/main_test.go @@ -214,7 +214,7 @@ func TestVersionOption(t *testing.T) { t.Errorf("error executing %s --version: %s", toolname, err.Error()) } // We are using MustCompile here, because hard-coded RE should not fail - re := regexp.MustCompile(toolname + `\n.*Version v?\d+\.\d+\.\d+\n`) + re := regexp.MustCompile(toolname + `\n.*Version v?\d+\.\d+\.\d+(-\d+)?\n`) if !re.Match(out) { t.Errorf("%s --version returns wrong result:\n%s", toolname, out) } diff --git a/src/go/pt-k8s-debug-collector/main_test.go b/src/go/pt-k8s-debug-collector/main_test.go index 834018645..e02d37f4f 100644 --- a/src/go/pt-k8s-debug-collector/main_test.go +++ b/src/go/pt-k8s-debug-collector/main_test.go @@ -279,7 +279,7 @@ func TestVersionOption(t *testing.T) { t.Errorf("error executing %s --version: %s", toolname, err.Error()) } // We are using MustCompile here, because hard-coded RE should not fail - re := regexp.MustCompile(toolname + `\n.*Version v?\d+\.\d+\.\d+\n`) + re := regexp.MustCompile(toolname + `\n.*Version v?\d+\.\d+\.\d+(-\d+)?\n`) if !re.Match(out) { t.Errorf("%s --version returns wrong result:\n%s", toolname, out) } diff --git a/src/go/pt-mongodb-index-check/main_test.go b/src/go/pt-mongodb-index-check/main_test.go index 866885263..adbc55d62 100644 --- a/src/go/pt-mongodb-index-check/main_test.go +++ b/src/go/pt-mongodb-index-check/main_test.go @@ -29,7 +29,7 @@ func TestVersionOption(t *testing.T) { t.Errorf("error executing %s --version: %s", toolname, err.Error()) } // We are using MustCompile here, because hard-coded RE should not fail - re := regexp.MustCompile(toolname + `\n.*Version v?\d+\.\d+\.\d+\n`) + re := regexp.MustCompile(toolname + `\n.*Version v?\d+\.\d+\.\d+(-\d+)?\n`) if !re.Match(out) { t.Errorf("%s --version returns wrong result:\n%s", toolname, out) } diff --git a/src/go/pt-pg-summary/main_test.go b/src/go/pt-pg-summary/main_test.go index 67613a43f..f8079b88b 100644 --- a/src/go/pt-pg-summary/main_test.go +++ b/src/go/pt-pg-summary/main_test.go @@ -148,7 +148,7 @@ func TestVersionOption(t *testing.T) { t.Errorf("error executing %s --version: %s", toolname, err.Error()) } // We are using MustCompile here, because hard-coded RE should not fail - re := regexp.MustCompile(toolname + `\n.*Version v?\d+\.\d+\.\d+\n`) + re := regexp.MustCompile(toolname + `\n.*Version v?\d+\.\d+\.\d+(-\d+)?\n`) if !re.Match(out) { t.Errorf("%s --version returns wrong result:\n%s", toolname, out) } diff --git a/src/go/pt-secure-collect/main_test.go b/src/go/pt-secure-collect/main_test.go index 4a028cafb..d4a633d0e 100644 --- a/src/go/pt-secure-collect/main_test.go +++ b/src/go/pt-secure-collect/main_test.go @@ -63,7 +63,7 @@ func TestVersionOption(t *testing.T) { t.Errorf("error executing %s --version: %s", toolname, err.Error()) } // We are using MustCompile here, because hard-coded RE should not fail - re := regexp.MustCompile(toolname + `\n.*Version v?\d+\.\d+\.\d+\n`) + re := regexp.MustCompile(toolname + `\n.*Version v?\d+\.\d+\.\d+(-\d+)?\n`) if !re.Match(out) { t.Errorf("%s --version returns wrong result:\n%s", toolname, out) }