Skip to content

Commit f0d8fb4

Browse files
committed
CR changes
1 parent 3b91bad commit f0d8fb4

File tree

5 files changed

+4
-8
lines changed

5 files changed

+4
-8
lines changed

commands/audit/audit_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -613,7 +613,6 @@ func TestAuditWithConfigProfile(t *testing.T) {
613613
SetXscVersion(services.ConfigProfileMinXscVersion).
614614
SetOutputFormat(format.Table).
615615
SetUseJas(true).
616-
SetIsRecursiveScan(true).
617616
SetConfigProfile(&configProfile)
618617

619618
auditParams := NewAuditParams().

tests/utils/integration/test_integrationutils.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -521,12 +521,10 @@ func InitTestHomeResources() (cleanUp func()) {
521521
}
522522

523523
func PrepareJfrogHomeResources(details *config.ServerDetails) (err error) {
524-
// Prepare the Analyzer Manager resource.
525524
if err = testUtils.PrepareAnalyzerManagerResource(); err != nil {
526525
return fmt.Errorf("failed to prepare analyzer manager resource: %w", err)
527526
}
528-
// Prepare the Xray Indexer resource.
529-
if err = testUtils.PrepareIndexerResource(details); err != nil {
527+
if err = testUtils.PrepareIndexerAppResource(details); err != nil {
530528
return fmt.Errorf("failed to prepare Xray Indexer resource: %w", err)
531529
}
532530
return

tests/utils/test_utils.go

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -432,24 +432,21 @@ func CreateTestProjectFromZipAndChdir(t *testing.T, projectPath string) (string,
432432
// Make sure to call this function before running any tests that require the analyzer manager binary.
433433
func PrepareAnalyzerManagerResource() (err error) {
434434
if localPath := os.Getenv(configTests.TestJfrogLocalAnalyzerManagerDirEnvVar); localPath != "" {
435-
// Copy the analyzer manager binary to the current JFrog Home.
436435
amLocalPath, err := jas.GetAnalyzerManagerDirAbsolutePath()
437436
if err != nil {
438437
return fmt.Errorf("failed to get analyzer manager local path: %w", err)
439438
}
440-
// if exists, no need to copy
441439
if exist, err := fileutils.IsDirExists(amLocalPath, false); err != nil || exist {
442440
return err
443441
}
444442
if err := biutils.CopyDir(localPath, amLocalPath, true, []string{}); err != nil {
445443
return fmt.Errorf("failed to copy analyzer manager from %s to %s: %w", localPath, amLocalPath, err)
446444
}
447445
}
448-
// Download the analyzer manager binary if it doesn't exist to current JFrog Home.
449446
return jas.DownloadAnalyzerManagerIfNeeded(0)
450447
}
451448

452-
func PrepareIndexerResource(details *config.ServerDetails) (err error) {
449+
func PrepareIndexerAppResource(details *config.ServerDetails) (err error) {
453450
manager, version, err := xrayUtils.CreateXrayServiceManagerAndGetVersion(details)
454451
if err != nil {
455452
return fmt.Errorf("failed to create Xray service manager: %w", err)

tests/validations/test_validation.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -394,6 +394,7 @@ func ValidateCommandOutput(t *testing.T, output string, outFormat format.OutputF
394394
case format.CycloneDx:
395395
VerifyCycloneDxResults(t, output, params)
396396
default:
397+
// SARIF format is not supported for validations (not implemented)
397398
t.Fatalf("Unsupported output format: %s", outFormat)
398399
}
399400
}

xsc_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ func TestXscAuditNpmJsonWithWatch(t *testing.T) {
4747
format: format.SimpleJson,
4848
withVuln: true,
4949
},
50+
// SARIF format is not supported for validations (not implemented)
5051
}
5152
for _, tc := range testCases {
5253
t.Run(tc.name, func(t *testing.T) {

0 commit comments

Comments
 (0)