Skip to content

Commit

Permalink
tiny fix
Browse files Browse the repository at this point in the history
  • Loading branch information
tennix committed Feb 27, 2019
1 parent a58e58c commit 042ce32
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
7 changes: 4 additions & 3 deletions tests/e2e/create.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,13 +60,14 @@ type Response struct {
func testCreate(ns, clusterName string) {
By(fmt.Sprintf("When create the TiDB cluster: %s/%s", ns, clusterName))
instanceName := getInstanceName(ns, clusterName)
err := createSecret(ns, clusterName)
Expect(err).NotTo(HaveOccurred())

cmdStr := fmt.Sprintf("helm install /charts/tidb-cluster -f /tidb-cluster-values.yaml"+
" -n %s --namespace=%s --set clusterName=%s,tidb.passwordSecretName=%s",
instanceName, ns, clusterName, ns+"-"+clusterName)
_, err = execCmd(cmdStr)
_, err := execCmd(cmdStr)
Expect(err).NotTo(HaveOccurred())

err = createSecret(ns, clusterName)
Expect(err).NotTo(HaveOccurred())

By("Then all members should running")
Expand Down
2 changes: 1 addition & 1 deletion tests/e2e/test_helper.go
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ func clearOperator() error {
return err
}
err = kubeCli.CoreV1().Secrets(fixture.ns).Delete(fixture.ns+"-"+fixture.clusterName, nil)
if err != nil && apierrs.IsNotFound(err) {
if err != nil && !apierrs.IsNotFound(err) {
return err
}
}
Expand Down

0 comments on commit 042ce32

Please sign in to comment.