Skip to content

Commit 739d5ee

Browse files
committed
Remove e2e test as we don't store sources/logs
1 parent 4d37201 commit 739d5ee

File tree

316 files changed

+1
-64433
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

316 files changed

+1
-64433
lines changed

go.mod

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,9 @@ go 1.22.0
55
toolchain go1.22.6
66

77
require (
8-
github.com/CycloneDX/cyclonedx-go v0.9.0
98
github.com/aws/aws-sdk-go v1.54.19
109
github.com/go-logr/logr v1.4.2
11-
github.com/google/go-containerregistry v0.20.1
10+
github.com/google/go-containerregistry v0.20.1 // indirect
1211
github.com/google/uuid v1.6.0
1312
github.com/konflux-ci/image-controller v0.0.0-20240809150447-338fc0d1a859
1413
github.com/onsi/gomega v1.34.1
@@ -42,12 +41,8 @@ require (
4241
github.com/blendle/zapdriver v1.3.1 // indirect
4342
github.com/census-instrumentation/opencensus-proto v0.4.1 // indirect
4443
github.com/cespare/xxhash/v2 v2.2.0 // indirect
45-
github.com/containerd/stargz-snapshotter/estargz v0.14.3 // indirect
4644
github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect
47-
github.com/docker/cli v26.1.2+incompatible // indirect
48-
github.com/docker/distribution v2.8.3+incompatible // indirect
4945
github.com/docker/docker v26.1.5+incompatible // indirect
50-
github.com/docker/docker-credential-helpers v0.8.0 // indirect
5146
github.com/emicklei/go-restful/v3 v3.11.0 // indirect
5247
github.com/evanphx/json-patch v5.6.0+incompatible // indirect
5348
github.com/evanphx/json-patch/v5 v5.9.0 // indirect
@@ -83,7 +78,6 @@ require (
8378
github.com/josharian/intern v1.0.0 // indirect
8479
github.com/json-iterator/go v1.1.12 // indirect
8580
github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51 // indirect
86-
github.com/klauspost/compress v1.17.4 // indirect
8781
github.com/ktr0731/go-ansisgr v0.1.0 // indirect
8882
github.com/ktr0731/go-fuzzyfinder v0.8.0 // indirect
8983
github.com/liggitt/tabwriter v0.0.0-20181228230101-89fcab3d43de // indirect
@@ -93,28 +87,24 @@ require (
9387
github.com/mattn/go-isatty v0.0.20 // indirect
9488
github.com/mattn/go-runewidth v0.0.15 // indirect
9589
github.com/mgutz/ansi v0.0.0-20200706080929-d51e80ef957d // indirect
96-
github.com/mitchellh/go-homedir v1.1.0 // indirect
9790
github.com/moby/term v0.0.0-20221205130635-1aeaba878587 // indirect
9891
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
9992
github.com/modern-go/reflect2 v1.0.2 // indirect
10093
github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00 // indirect
10194
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
10295
github.com/nsf/termbox-go v1.1.1 // indirect
10396
github.com/opencontainers/go-digest v1.0.0 // indirect
104-
github.com/opencontainers/image-spec v1.1.0 // indirect
10597
github.com/peterbourgon/diskv v2.0.1+incompatible // indirect
10698
github.com/pkg/errors v0.9.1 // indirect
10799
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
108100
github.com/prometheus/common v0.51.1 // indirect
109101
github.com/prometheus/procfs v0.12.0 // indirect
110102
github.com/prometheus/statsd_exporter v0.22.7 // indirect
111103
github.com/rivo/uniseg v0.4.4 // indirect
112-
github.com/sirupsen/logrus v1.9.3 // indirect
113104
github.com/spf13/cobra v1.8.0 // indirect
114105
github.com/spf13/pflag v1.0.5 // indirect
115106
github.com/stoewer/go-strcase v1.2.0 // indirect
116107
github.com/tektoncd/triggers v0.27.0 // indirect
117-
github.com/vbatts/tar-split v0.11.5 // indirect
118108
github.com/xlab/treeprint v1.2.0 // indirect
119109
go.opencensus.io v0.24.0 // indirect
120110
go.starlark.net v0.0.0-20230525235612-a134d8f9ddca // indirect

go.sum

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,6 @@ github.com/Azure/go-autorest/logger v0.2.0/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZ
4848
github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU=
4949
github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
5050
github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo=
51-
github.com/CycloneDX/cyclonedx-go v0.9.0 h1:inaif7qD8bivyxp7XLgxUYtOXWtDez7+j72qKTMQTb8=
52-
github.com/CycloneDX/cyclonedx-go v0.9.0/go.mod h1:NE/EWvzELOFlG6+ljX/QeMlVt9VKcTwu8u0ccsACEsw=
5351
github.com/NYTimes/gziphandler v0.0.0-20170623195520-56545f4a5d46/go.mod h1:3wb06e3pkSAbeQ52E9H9iFoQsEEwGN64994WTCIhntQ=
5452
github.com/Netflix/go-expect v0.0.0-20220104043353-73e0943537d2 h1:+vx7roKuyA63nhn5WAunQHLTznkw5W8b1Xc0dNjp83s=
5553
github.com/Netflix/go-expect v0.0.0-20220104043353-73e0943537d2/go.mod h1:HBCaDeC1lPdgDeDbhX8XFpy1jqjK0IBG8W5K+xYqA0w=
@@ -74,8 +72,6 @@ github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM=
7472
github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw=
7573
github.com/blendle/zapdriver v1.3.1 h1:C3dydBOWYRiOk+B8X9IVZ5IOe+7cl+tGOexN4QqHfpE=
7674
github.com/blendle/zapdriver v1.3.1/go.mod h1:mdXfREi6u5MArG4j9fewC+FGnXaBR+T4Ox4J2u4eHCc=
77-
github.com/bradleyjkemp/cupaloy/v2 v2.8.0 h1:any4BmKE+jGIaMpnU8YgH/I2LPiLBufr6oMMlVBbn9M=
78-
github.com/bradleyjkemp/cupaloy/v2 v2.8.0/go.mod h1:bm7JXdkRd4BHJk9HpwqAI8BoAY1lps46Enkdqw6aRX0=
7975
github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU=
8076
github.com/census-instrumentation/opencensus-proto v0.4.1 h1:iKLQ0xPNFxR/2hzXZMrBo8f1j86j5WHzznCCQxV/b8g=
8177
github.com/census-instrumentation/opencensus-proto v0.4.1/go.mod h1:4T9NM4+4Vw91VeyqjLS6ao50K5bOcLKN6Q42XnYaRYw=
@@ -522,8 +518,6 @@ github.com/tektoncd/pipeline v0.59.2 h1:hspD31XWToUIFnUFkUitjqGBnW0hd9Q9cVHYbhjp
522518
github.com/tektoncd/pipeline v0.59.2/go.mod h1:VjXZUGLrOy45B35ufbJZ2DLMt+TSJ3R4ZjKJvi7RWg4=
523519
github.com/tektoncd/triggers v0.27.0 h1:c55e/YJF6Vs5BEarqDYksFYuR4sFbmAVEqrLNPZvXUk=
524520
github.com/tektoncd/triggers v0.27.0/go.mod h1:DkkAkdSd9aAW9RklUVyFRKQ8kONmZQw4Ur2G1r3wFQo=
525-
github.com/terminalstatic/go-xsd-validate v0.1.5 h1:RqpJnf6HGE2CB/lZB1A8BYguk8uRtcvYAPLCF15qguo=
526-
github.com/terminalstatic/go-xsd-validate v0.1.5/go.mod h1:18lsvYFofBflqCrvo1umpABZ99+GneNTw2kEEc8UPJw=
527521
github.com/tidwall/gjson v1.12.1 h1:ikuZsLdhr8Ws0IdROXUS1Gi4v9Z4pGqpX/CvJkxvfpo=
528522
github.com/tidwall/gjson v1.12.1/go.mod h1:/wbyibRr2FHMks5tjHJ5F8dMZh3AcwJEMf5vlfC0lxk=
529523
github.com/tidwall/match v1.1.1 h1:+Ho715JplO36QYgwN9PGYNhgZvoUSc9X2c80KVTi+GA=
@@ -536,12 +530,6 @@ github.com/titanous/rocacheck v0.0.0-20171023193734-afe73141d399 h1:e/5i7d4oYZ+C
536530
github.com/titanous/rocacheck v0.0.0-20171023193734-afe73141d399/go.mod h1:LdwHTNJT99C5fTAzDz0ud328OgXz+gierycbcIx2fRs=
537531
github.com/vbatts/tar-split v0.11.5 h1:3bHCTIheBm1qFTcgh9oPu+nNBtX+XJIupG/vacinCts=
538532
github.com/vbatts/tar-split v0.11.5/go.mod h1:yZbwRsSeGjusneWgA781EKej9HF8vme8okylkAeNKLk=
539-
github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f h1:J9EGpcZtP0E/raorCMxlFGSTBrsSlaDGf3jU/qvAE2c=
540-
github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU=
541-
github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415 h1:EzJWgHovont7NscjpAxXsDA8S8BMYve8Y5+7cuRE7R0=
542-
github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ=
543-
github.com/xeipuuv/gojsonschema v1.2.0 h1:LhYJRs+L4fBtjZUfuSZIKGeVu0QRy8e5Xi7D17UxZ74=
544-
github.com/xeipuuv/gojsonschema v1.2.0/go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y=
545533
github.com/xlab/treeprint v1.2.0 h1:HzHnuAF1plUN2zGlAFHbSQP2qJ0ZAD3XF5XD7OesXRQ=
546534
github.com/xlab/treeprint v1.2.0/go.mod h1:gj5Gd3gPdKtR1ikdDK6fnFLdmIS0X30kTTuNd/WEJu0=
547535
github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=

openshift-with-appstudio-test/e2e/basictests.go

Lines changed: 0 additions & 114 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
package e2e
22

33
import (
4-
"archive/tar"
5-
"compress/gzip"
64
"context"
75
"encoding/json"
86
"fmt"
@@ -17,10 +15,6 @@ import (
1715
"testing"
1816
"time"
1917

20-
cdx "github.com/CycloneDX/cyclonedx-go"
21-
"github.com/google/go-containerregistry/pkg/crane"
22-
"github.com/google/go-containerregistry/pkg/name"
23-
"github.com/google/go-containerregistry/pkg/v1/remote"
2418
"github.com/redhat-appstudio/jvm-build-service/pkg/apis/jvmbuildservice/v1alpha1"
2519
"github.com/redhat-appstudio/jvm-build-service/pkg/reconciler/artifactbuild"
2620
tektonpipeline "github.com/tektoncd/pipeline/pkg/apis/pipeline/v1"
@@ -447,114 +441,6 @@ func runAbTests(path string, testSet string, pipeline string, ta *testArgs) {
447441
debugAndFailTest(ta, "timed out waiting for contaminated build to appear")
448442
}
449443
})
450-
451-
ta.t.Run("Logs and source included in image", func(t *testing.T) {
452-
453-
rebuiltList, err := jvmClient.JvmbuildserviceV1alpha1().RebuiltArtifacts(ta.ns).List(context.TODO(), metav1.ListOptions{})
454-
if err != nil {
455-
panic(err)
456-
}
457-
for _, artifact := range rebuiltList.Items {
458-
sourceFound := false
459-
logsFound := false
460-
sbomFound := false
461-
imageName := artifact.Spec.Image
462-
463-
if !strings.Contains(imageName, "quay.io") {
464-
//skip this on the minikube tests
465-
//we can't access the internal image registry
466-
continue
467-
}
468-
469-
println(imageName)
470-
ref, err := name.ParseReference(imageName)
471-
if err != nil {
472-
panic(err)
473-
}
474-
475-
rmt, err := remote.Get(ref)
476-
if err != nil {
477-
panic(err)
478-
}
479-
480-
img, err := rmt.Image()
481-
if err != nil {
482-
panic(err)
483-
}
484-
export := path + "/foo.tar"
485-
if err := crane.Save(img, "foo", export); err != nil {
486-
panic(err)
487-
}
488-
f, err := os.Open(export) //#nosec G304
489-
if err != nil {
490-
panic(err)
491-
}
492-
defer func() {
493-
if err := f.Close(); err != nil {
494-
panic(err)
495-
}
496-
}()
497-
tr := tar.NewReader(f)
498-
for {
499-
cur, err := tr.Next()
500-
if err == io.EOF {
501-
break
502-
} else if err != nil {
503-
panic(err)
504-
}
505-
if cur.Typeflag != tar.TypeReg {
506-
continue
507-
}
508-
println(cur.Name)
509-
if strings.HasSuffix(cur.Name, ".tar.gz") {
510-
zip, err := gzip.NewReader(tr)
511-
if err != nil {
512-
panic(err)
513-
}
514-
innerTar := tar.NewReader(zip)
515-
for {
516-
cur, err := innerTar.Next()
517-
if err == io.EOF {
518-
break
519-
} else if err != nil {
520-
panic(err)
521-
}
522-
if cur.Typeflag != tar.TypeReg {
523-
continue
524-
}
525-
println(cur.Name)
526-
if cur.Name == "./maven.log" || cur.Name == "./gradle.log" {
527-
logsFound = true
528-
} else if cur.Name == "./.git/HEAD" {
529-
sourceFound = true
530-
} else if cur.Name == "./build-sbom.json" {
531-
sbomFound = true
532-
bom := &cdx.BOM{}
533-
decoder := cdx.NewBOMDecoder(innerTar, cdx.BOMFileFormatJSON)
534-
if err = decoder.Decode(bom); err != nil {
535-
panic(err)
536-
}
537-
if bom.Dependencies != nil && len(*bom.Dependencies) < 30 {
538-
_ = cdx.NewBOMEncoder(os.Stdout, cdx.BOMFileFormatXML).
539-
SetPretty(true).
540-
Encode(bom)
541-
panic("Not enough dependencies in build SBom")
542-
}
543-
}
544-
}
545-
}
546-
}
547-
if !sourceFound {
548-
panic("Source was not found in image " + imageName)
549-
}
550-
if !logsFound {
551-
panic("Logs were not found in image " + imageName)
552-
}
553-
if !sbomFound {
554-
panic("Build SBOM were not found in image " + imageName)
555-
}
556-
}
557-
})
558444
}
559445

560446
func runDbTests(path string, testSet string, ta *testArgs) {

vendor/github.com/CycloneDX/cyclonedx-go/.gitignore

Lines changed: 0 additions & 24 deletions
This file was deleted.

vendor/github.com/CycloneDX/cyclonedx-go/.gitpod.yml

Lines changed: 0 additions & 9 deletions
This file was deleted.

vendor/github.com/CycloneDX/cyclonedx-go/.golangci.yml

Lines changed: 0 additions & 7 deletions
This file was deleted.

vendor/github.com/CycloneDX/cyclonedx-go/.goreleaser.yml

Lines changed: 0 additions & 44 deletions
This file was deleted.

vendor/github.com/CycloneDX/cyclonedx-go/.licenserc.yml

Lines changed: 0 additions & 39 deletions
This file was deleted.

vendor/github.com/CycloneDX/cyclonedx-go/CODEOWNERS

Lines changed: 0 additions & 1 deletion
This file was deleted.

vendor/github.com/CycloneDX/cyclonedx-go/Dockerfile.gitpod

Lines changed: 0 additions & 18 deletions
This file was deleted.

0 commit comments

Comments
 (0)