Skip to content

Commit fc00b7f

Browse files
committed
test: Fix JBoss EAP 8.0 version
Stick to the EAP 8.0 manifest version 1.6.1.GA-redhat-00006 for testing the extraction of the runtime data. Signed-off-by: Jeff Mesnil <[email protected]>
1 parent 091abc9 commit fc00b7f

File tree

1 file changed

+17
-15
lines changed

1 file changed

+17
-15
lines changed

exporter/test/e2e/jboss_eap_test.go

Lines changed: 17 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -103,34 +103,36 @@ func TestJBossEAP_8_0(t *testing.T) {
103103
appName := "jboss-eap-8-0-app"
104104

105105
feature := features.New("JBoss EAP 8.0 from Helm release").
106-
Setup(deployTestHelmRelease(appName)).
106+
Setup(deployTestHelmRelease_8_0(appName)).
107107
Teardown(undeployTestHelmRelease(appName)).
108108
Assess("runtime info extracted", checkExtractedRuntimeInfo(namespace, "app.kubernetes.io/name="+appName, appName, func(g *Ω.WithT, runtimeInfo types.ContainerRuntimeInfo) {
109-
g.Expect(runtimeInfo.Os).Should(Ω.Equal("rhel"))
110-
g.Expect(runtimeInfo.OsVersion).Should(Ω.Equal("8.10"))
111-
g.Expect(runtimeInfo.Kind).Should(Ω.Equal("Java"))
112-
g.Expect(runtimeInfo.KindVersion).Should(Ω.HavePrefix("17.0"))
113-
g.Expect(runtimeInfo.KindImplementer).Should(Ω.Equal("Red Hat, Inc."))
114-
115-
/*
116-
temporary skip these assertions.
117-
g.Expect(len(runtimeInfo.Runtimes)).Should(Ω.Equal(1))
118-
runtime := runtimeInfo.Runtimes[0]
119-
g.Expect(runtime.Name).Should(Ω.Equal("Red Hat JBoss Enterprise Application Platform"))
120-
g.Expect(runtime.Version).Should(Ω.HavePrefix("8.0 Update"))
121-
*/
109+
expected := types.ContainerRuntimeInfo{
110+
Os: "rhel",
111+
OsVersion: "8.10",
112+
Kind: "Java",
113+
KindVersion: "17.0.14",
114+
KindImplementer: "Red Hat, Inc.",
115+
Runtimes: []types.RuntimeComponent{{
116+
Name: "Red Hat JBoss Enterprise Application Platform",
117+
Version: "8.0 Update 6.1",
118+
}},
119+
}
120+
g.Expect(runtimeInfo).Should(Ω.Equal(expected))
122121
}))
123122
_ = testenv.Test(t, feature.Feature())
124123
}
125124

126-
func deployTestHelmRelease(appName string) func(context.Context, *testing.T, *envconf.Config) context.Context {
125+
func deployTestHelmRelease_8_0(appName string) func(context.Context, *testing.T, *envconf.Config) context.Context {
127126
return func(ctx context.Context, t *testing.T, c *envconf.Config) context.Context {
128127
g := Ω.NewWithT(t)
129128

130129
manager := helm.New(c.KubeconfigFile())
131130
if err := manager.RunInstall(helm.WithChart("https://github.com/jbossas/eap-charts/releases/download/eap8-1.1.2/eap8-1.1.2.tgz"),
132131
helm.WithNamespace(namespace),
133132
helm.WithName(appName),
133+
helm.WithArgs("--set", "build.uri=https://github.com/openshift/insights-runtime-extractor"),
134+
helm.WithArgs("--set", "build.contextDir=runtime-samples/jboss-eap/8.0"),
135+
helm.WithArgs("--set", "build.s2i.jkd17.runtimeImage=registry.redhat.io/jboss-eap-8/eap8-openjdk17-runtime-openshift-rhel8@sha256:d16346922c00c0430b3a3a6b3a47c910a23063a8a679a5c1b2d32fd96b92a225"),
134136
); err != nil {
135137
g.Expect(err).ShouldNot(Ω.HaveOccurred())
136138
}

0 commit comments

Comments
 (0)