Skip to content

Commit

Permalink
newlines
Browse files Browse the repository at this point in the history
  • Loading branch information
AustinAbro321 committed Jul 12, 2024
1 parent 4a67ae8 commit 5473d3d
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions src/pkg/lint/lint.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ func Validate(ctx context.Context, createOpts types.ZarfCreateOptions) error {
if err := os.Chdir(createOpts.BaseDir); err != nil {
return fmt.Errorf("unable to access directory %q: %w", createOpts.BaseDir, err)

Check warning on line 26 in src/pkg/lint/lint.go

View check run for this annotation

Codecov / codecov/patch

src/pkg/lint/lint.go#L23-L26

Added lines #L23 - L26 were not covered by tests
}

var pkg types.ZarfPackage
if err := utils.ReadYaml(layout.ZarfYAML, &pkg); err != nil {
return err

Check warning on line 30 in src/pkg/lint/lint.go

View check run for this annotation

Codecov / codecov/patch

src/pkg/lint/lint.go#L28-L30

Added lines #L28 - L30 were not covered by tests
Expand All @@ -36,7 +35,6 @@ func Validate(ctx context.Context, createOpts types.ZarfCreateOptions) error {
return err

Check warning on line 35 in src/pkg/lint/lint.go

View check run for this annotation

Codecov / codecov/patch

src/pkg/lint/lint.go#L33-L35

Added lines #L33 - L35 were not covered by tests
}
findings = append(findings, compFindings...)

schemaFindings, err := ValidateSchema()
if err != nil {
return err

Check warning on line 40 in src/pkg/lint/lint.go

View check run for this annotation

Codecov / codecov/patch

src/pkg/lint/lint.go#L37-L40

Added lines #L37 - L40 were not covered by tests
Expand All @@ -47,13 +45,10 @@ func Validate(ctx context.Context, createOpts types.ZarfCreateOptions) error {
message.Successf("0 findings for %q", pkg.Metadata.Name)
return nil

Check warning on line 46 in src/pkg/lint/lint.go

View check run for this annotation

Codecov / codecov/patch

src/pkg/lint/lint.go#L44-L46

Added lines #L44 - L46 were not covered by tests
}

PrintFindings(findings, SevWarn, createOpts.BaseDir, pkg.Metadata.Name)

if HasSevOrHigher(findings, SevErr) {
return errors.New("errors during lint")

Check warning on line 50 in src/pkg/lint/lint.go

View check run for this annotation

Codecov / codecov/patch

src/pkg/lint/lint.go#L48-L50

Added lines #L48 - L50 were not covered by tests
}

return nil

Check warning on line 52 in src/pkg/lint/lint.go

View check run for this annotation

Codecov / codecov/patch

src/pkg/lint/lint.go#L52

Added line #L52 was not covered by tests
}

Expand Down

0 comments on commit 5473d3d

Please sign in to comment.