Skip to content

Fix 'occured' -> 'occurred' typos across e2e tests and monitors (8 files, 31 instances)#31026

Open
SAY-5 wants to merge 8 commits intoopenshift:mainfrom
SAY-5:fix-occured-typos
Open

Fix 'occured' -> 'occurred' typos across e2e tests and monitors (8 files, 31 instances)#31026
SAY-5 wants to merge 8 commits intoopenshift:mainfrom
SAY-5:fix-occured-typos

Conversation

@SAY-5
Copy link
Copy Markdown

@SAY-5 SAY-5 commented Apr 17, 2026

Fix 31 instances of `occured` → `occurred` across 8 test/monitor files.

Files

File Instances
`test/extended/machine_config/machine_config_node.go` 18
`test/extended/kernel/kernel_rt_latency.go` 3
`test/extended/kernel/kernel_rt_functional.go` 3
`test/extended/machine_config/helpers.go` 2
`test/extended/machine_config/pinnedimages.go` 2
`pkg/monitortests/monitoring/statefulsetsrecreation/monitortest.go` 1
`pkg/monitortests/network/legacynetworkmonitortests/disruption.go` 1
`test/extended/machines/machines.go` 1

All are in Gomega assertion failure-messages (`o.Expect(err).NotTo(o.HaveOccurred(), "Error occured while ...")`) or similar. String-literal-only change; no behavior change.

Note: the Gomega `HaveOccurred` matcher (already correctly double-R) is untouched — only the human-readable error messages are corrected.

Summary by CodeRabbit

  • Chores
    • Corrected spelling errors in test assertion and logging messages across kernel, machine config, and related test modules.

SAY-5 added 8 commits April 16, 2026 21:52
Signed-off-by: SAY-5 <SAY-5@users.noreply.github.com>
Signed-off-by: SAY-5 <SAY-5@users.noreply.github.com>
Signed-off-by: SAY-5 <SAY-5@users.noreply.github.com>
Signed-off-by: SAY-5 <SAY-5@users.noreply.github.com>
Signed-off-by: SAY-5 <SAY-5@users.noreply.github.com>
Signed-off-by: SAY-5 <SAY-5@users.noreply.github.com>
Signed-off-by: SAY-5 <SAY-5@users.noreply.github.com>
Signed-off-by: SAY-5 <SAY-5@users.noreply.github.com>
@openshift-merge-bot
Copy link
Copy Markdown
Contributor

Pipeline controller notification
This repo is configured to use the pipeline controller. Second-stage tests will be triggered either automatically or after lgtm label is added, depending on the repository configuration. The pipeline controller will automatically detect which contexts are required and will utilize /test Prow commands to trigger the second stage.

For optional jobs, comment /test ? to see a list of all defined jobs. To trigger manually all jobs from second stage use /pipeline required command.

This repository is configured in: automatic mode

@openshift-ci openshift-ci Bot added the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Apr 17, 2026
@openshift-ci
Copy link
Copy Markdown
Contributor

openshift-ci Bot commented Apr 17, 2026

Hi @SAY-5. Thanks for your PR.

I'm waiting for a openshift member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work.

Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@openshift-ci
Copy link
Copy Markdown
Contributor

openshift-ci Bot commented Apr 17, 2026

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: SAY-5
Once this PR has been reviewed and has the lgtm label, please assign dgoodwin for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Apr 17, 2026

Walkthrough

Corrected spelling of "occured" to "occurred" in log messages and test assertion failure messages across monitoring and testing files. No functional behavior, control flow, or logic was modified.

Changes

Cohort / File(s) Summary
Monitoring tests
pkg/monitortests/monitoring/statefulsetsrecreation/monitortest.go
Updated log message spelling in getStatefulsetsUID function from "Error occured" to "Error occurred".
Kernel tests
test/extended/kernel/kernel_rt_functional.go, test/extended/kernel/kernel_rt_latency.go
Corrected spelling in Gomega assertion failure messages from "error occured" to "error occurred" across multiple test cases (pi_stress, deadline_test, hwlatdetect, oslat, cyclictest).
Machine config tests
test/extended/machine_config/helpers.go, test/extended/machine_config/machine_config_node.go, test/extended/machine_config/pinnedimages.go
Corrected spelling of "occured" to "occurred" in error messages throughout condition validation and status checking functions across multiple MCN condition checks and PinnedImageSet status assertions.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

🚥 Pre-merge checks | ✅ 9 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Test Structure And Quality ❓ Inconclusive PR has incomplete typo fixes and mismatched assertion messages that make test failures misleading. Fix remaining 'occured' typo in pinnedimages.go line 518 and correct mismatched assertion messages in machine_config_node.go to match validated conditions.
✅ Passed checks (9 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: fixing 'occured' to 'occurred' typos across test and monitor files, with specific details about file count and instance count.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.
Stable And Deterministic Test Names ✅ Passed PR only fixes typos in assertion messages and error logging strings, not in test names. No test titles are modified and no dynamic information is introduced in test names.
Microshift Test Compatibility ✅ Passed This PR modifies only spelling corrections in assertion error messages within existing tests; no new Ginkgo e2e tests are added.
Single Node Openshift (Sno) Test Compatibility ✅ Passed PR contains only typo corrections in assertion failure messages and helper function text; no new Ginkgo e2e tests introduced, so SNO compatibility check does not apply.
Topology-Aware Scheduling Compatibility ✅ Passed Pull request contains only spelling typo corrections in test files and monitor tests; no deployment manifests, operator code, or controllers with scheduling constraints are modified.
Ote Binary Stdout Contract ✅ Passed PR modifies only string literals correcting typos in existing logging/assertion statements without introducing new stdout-writing code.
Ipv6 And Disconnected Network Test Compatibility ✅ Passed This PR only corrects spelling in existing assertion messages without adding new Ginkgo e2e tests, making the custom check not applicable.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
test/extended/machine_config/helpers.go (1)

606-611: ⚠️ Potential issue | 🟡 Minor

One typo still remains in this same error path.

You fixed Line 606, but Line 610 still says "occured".

Suggested patch
-		framework.Logf("A timeout occured waiting for MCN '%v' %v condition was not %v.", mcnName, conditionType, status)
+		framework.Logf("A timeout occurred waiting for MCN '%v' %v condition was not %v.", mcnName, conditionType, status)
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@test/extended/machine_config/helpers.go` around lines 606 - 611, Fix the
remaining typo in the timeout log message: locate the logging call that uses
framework.Logf with the message "A timeout occured waiting for MCN '%v' %v
condition was not %v." (the call that references mcnName, conditionType, status
and returns conditionMet,nil) and change "occured" to the correct spelling
"occurred" so the log reads "A timeout occurred waiting for MCN '%v' %v
condition was not %v."
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@test/extended/machine_config/machine_config_node.go`:
- Around line 378-382: The assertions after calling WaitForMCNConditionStatus
are checking for Uncordoned=True but their failure messages still refer to
UpdateComplete=True; update the two messages to match the actual condition being
waited on: when calling WaitForMCNConditionStatus(clientSet, updatingNodeName,
mcfgv1.MachineConfigNodeUpdateUncordoned, metav1.ConditionTrue, ...), change the
fmt.Sprintf error text and the o.Expect(...).To(o.BeTrue(), ...) message so they
mention "Uncordoned=True" (or similar clear text) instead of
"UpdateComplete=True" to avoid misleading failures.

In `@test/extended/machine_config/pinnedimages.go`:
- Around line 499-500: The test contains a typo "occured" in a nearby comment;
update the comment(s) that mention the error message to use the correct spelling
"occurred" (search for the string "occured" around the o.Expect(...) assertions
in pinnedimages.go, including the occurrences near the
o.Expect(err).NotTo(o.HaveOccurred(...)) line and the lines around the
PinnedImageSetsDegraded=True check) so all comments consistently read
"occurred".

---

Outside diff comments:
In `@test/extended/machine_config/helpers.go`:
- Around line 606-611: Fix the remaining typo in the timeout log message: locate
the logging call that uses framework.Logf with the message "A timeout occured
waiting for MCN '%v' %v condition was not %v." (the call that references
mcnName, conditionType, status and returns conditionMet,nil) and change
"occured" to the correct spelling "occurred" so the log reads "A timeout
occurred waiting for MCN '%v' %v condition was not %v."
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository: openshift/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 7bdb1cc5-5f77-4c69-963c-49df563b90c9

📥 Commits

Reviewing files that changed from the base of the PR and between d7ad0db and 9c4b011.

📒 Files selected for processing (6)
  • pkg/monitortests/monitoring/statefulsetsrecreation/monitortest.go
  • test/extended/kernel/kernel_rt_functional.go
  • test/extended/kernel/kernel_rt_latency.go
  • test/extended/machine_config/helpers.go
  • test/extended/machine_config/machine_config_node.go
  • test/extended/machine_config/pinnedimages.go

Comment on lines 378 to 382
framework.Logf("Waiting for Uncordoned=True")
conditionMet, err = WaitForMCNConditionStatus(clientSet, updatingNodeName, mcfgv1.MachineConfigNodeUpdateUncordoned, metav1.ConditionTrue, 10*time.Second, 1*time.Second)
o.Expect(err).NotTo(o.HaveOccurred(), fmt.Sprintf("Error occured while waiting for UpdateComplete=True: %v", err))
o.Expect(err).NotTo(o.HaveOccurred(), fmt.Sprintf("Error occurred while waiting for UpdateComplete=True: %v", err))
o.Expect(conditionMet).To(o.BeTrue(), "Error, could not detect UpdateComplete=True.")

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Assertion message mismatches the condition being validated.

At Line 379 you wait for Uncordoned=True, but Lines 380-381 still say UpdateComplete=True. This makes failures misleading.

Suggested patch
-	o.Expect(err).NotTo(o.HaveOccurred(), fmt.Sprintf("Error occurred while waiting for UpdateComplete=True: %v", err))
-	o.Expect(conditionMet).To(o.BeTrue(), "Error, could not detect UpdateComplete=True.")
+	o.Expect(err).NotTo(o.HaveOccurred(), fmt.Sprintf("Error occurred while waiting for Uncordoned=True: %v", err))
+	o.Expect(conditionMet).To(o.BeTrue(), "Error, could not detect Uncordoned=True.")
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@test/extended/machine_config/machine_config_node.go` around lines 378 - 382,
The assertions after calling WaitForMCNConditionStatus are checking for
Uncordoned=True but their failure messages still refer to UpdateComplete=True;
update the two messages to match the actual condition being waited on: when
calling WaitForMCNConditionStatus(clientSet, updatingNodeName,
mcfgv1.MachineConfigNodeUpdateUncordoned, metav1.ConditionTrue, ...), change the
fmt.Sprintf error text and the o.Expect(...).To(o.BeTrue(), ...) message so they
mention "Uncordoned=True" (or similar clear text) instead of
"UpdateComplete=True" to avoid misleading failures.

Comment on lines +499 to 500
o.Expect(err).NotTo(o.HaveOccurred(), fmt.Sprintf("Error occurred while waiting for PinnedImageSetsDegraded=True: %v", err))
o.Expect(conditionMet).To(o.BeTrue(), "Error, could not detect PinnedImageSetsDegraded=True.")
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Minor consistency follow-up: nearby comment still has a typo.

Line 499 is fixed, but Line 518 still says "occured" in the comment.

Suggested patch
-			// If we make it here, it means no fatal or non-fatal error has occured & the PIS application conditions were met
+			// If we make it here, it means no fatal or non-fatal error has occurred & the PIS application conditions were met

Also applies to: 518-519

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@test/extended/machine_config/pinnedimages.go` around lines 499 - 500, The
test contains a typo "occured" in a nearby comment; update the comment(s) that
mention the error message to use the correct spelling "occurred" (search for the
string "occured" around the o.Expect(...) assertions in pinnedimages.go,
including the occurrences near the o.Expect(err).NotTo(o.HaveOccurred(...)) line
and the lines around the PinnedImageSetsDegraded=True check) so all comments
consistently read "occurred".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant