Compare commits

..

1 Commits

Author SHA1 Message Date
shreyas-goenka b8af03523b
Merge 48f3bfb008 into e81ec4ee23 2025-02-10 23:30:29 +05:30
2 changed files with 6 additions and 7 deletions

View File

@ -28,7 +28,7 @@ test:
cover:
rm -fr ./acceptance/build/cover/
VERBOSE_TEST=1 CLI_GOCOVERDIR=build/cover ${GOTESTSUM_CMD} -- -coverprofile=coverage.txt ${PACKAGES}
CLI_GOCOVERDIR=build/cover ${GOTESTSUM_CMD} -- -coverprofile=coverage.txt ${PACKAGES}
rm -fr ./acceptance/build/cover-merged/
mkdir -p acceptance/build/cover-merged/
go tool covdata merge -i $$(printf '%s,' acceptance/build/cover/* | sed 's/,$$//') -o acceptance/build/cover-merged/
@ -61,6 +61,6 @@ integration: vendor
$(INTEGRATION)
integration-short: vendor
VERBOSE_TEST=1 $(INTEGRATION) -short
$(INTEGRATION) -short
.PHONY: lint tidy lintcheck fmt test cover showcover build snapshot vendor schema integration integration-short acc-cover acc-showcover docs

View File

@ -30,9 +30,8 @@ import (
)
var (
KeepTmp bool
NoRepl bool
VerboseTest bool = os.Getenv("VERBOSE_TEST") != ""
KeepTmp bool
NoRepl bool
)
// In order to debug CLI running under acceptance test, set this to full subtest name, e.g. "bundle/variables/empty"
@ -262,7 +261,7 @@ func runTest(t *testing.T, dir, coverDir string, repls testdiff.ReplacementsCont
// 2. The test is configured to record requests and assert on them. We need
// a duplicate of the default server to record requests because the default
// server otherwise is a shared resource.
if cloudEnv == "" && (len(config.Server) > 0 || config.RecordRequests) {
if len(config.Server) > 0 || config.RecordRequests {
server = testserver.New(t)
server.RecordRequests = config.RecordRequests
server.IncludeRequestHeaders = config.IncludeRequestHeaders
@ -413,7 +412,7 @@ func doComparison(t *testing.T, repls testdiff.ReplacementsContext, dirRef, dirN
testutil.WriteFile(t, pathRef, valueNew)
}
if VerboseTest && !equal && printedRepls != nil && !*printedRepls {
if !equal && printedRepls != nil && !*printedRepls {
*printedRepls = true
var items []string
for _, item := range repls.Repls {