Skip to content

Commit

Permalink
helpers: Fix looking for versioned rules
Browse files Browse the repository at this point in the history
We used to look for versioned rules under ruleTestDir/manifest, so
usually ocp4/e2e/4.10.yml or such. But that was incorrect, the versioned
manifests live under the rule dir, not the directory where tests are
executed from.

Jira: CMP-1415
  • Loading branch information
jhrozek committed Jun 28, 2022
1 parent 2666d09 commit 053e80a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -894,7 +894,7 @@ func (ctx *e2econtext) verifyRule(
// certain rules
func (ctx *e2econtext) getTestDefinition(rulePath string) ([]byte, error) {
versionedManifest := fmt.Sprintf("%s.yml", ctx.version)
versionedRuleTestFilePath := path.Join(ruleTestDir, versionedManifest)
versionedRuleTestFilePath := path.Join(rulePath, ruleTestDir, versionedManifest)
vbuf, verr := ioutil.ReadFile(versionedRuleTestFilePath)

if verr == nil {
Expand Down

0 comments on commit 053e80a

Please sign in to comment.