diff --git a/java/akka/smoke_test/akka_test.go b/java/akka/smoke_test/akka_test.go index ebcf0b96..ab3c167a 100644 --- a/java/akka/smoke_test/akka_test.go +++ b/java/akka/smoke_test/akka_test.go @@ -81,7 +81,7 @@ func testAkkaWithBuilder(builder string) func(*testing.T, spec.G, spec.S) { err = docker.Image.Remove.Execute(image.ID) if err != nil { - Expect(err.Error()).To(ContainSubstring("failed to remove docker image: exit status 1: Error")) + Expect(err).To(MatchError(ContainSubstring("failed to remove docker image: exit status 1: Error"))) } else { Expect(err).ToNot(HaveOccurred()) } diff --git a/java/application-insights/smoke_test/application_insights_test.go b/java/application-insights/smoke_test/application_insights_test.go index 5449fa44..59a1fbcc 100644 --- a/java/application-insights/smoke_test/application_insights_test.go +++ b/java/application-insights/smoke_test/application_insights_test.go @@ -80,7 +80,7 @@ func testApplicationInsightsWithBuilders(builder string) func(*testing.T, spec.G err = docker.Image.Remove.Execute(image.ID) if err != nil { - Expect(err).To(MatchError("failed to remove docker image: exit status 1: Error: No such image:")) + Expect(err).To(MatchError(ContainSubstring("failed to remove docker image: exit status 1: Error"))) } else { Expect(err).ToNot(HaveOccurred()) } @@ -91,7 +91,7 @@ func testApplicationInsightsWithBuilders(builder string) func(*testing.T, spec.G context("app uses application insights", func() { it("builds successfully", func() { var err error - source, err = occam.Source(filepath.Join("../java", "application-insights")) + source, err = occam.Source(filepath.Join("../../java", "application-insights")) Expect(err).NotTo(HaveOccurred()) var logs fmt.Stringer