Skip to content

test(jobs): add fake timers to data_set_lifecycle_check tests#637

Merged
silent-cipher merged 1 commit into
mainfrom
test/use-fake-timers
Jul 3, 2026
Merged

test(jobs): add fake timers to data_set_lifecycle_check tests#637
silent-cipher merged 1 commit into
mainfrom
test/use-fake-timers

Conversation

@silent-cipher

Copy link
Copy Markdown
Collaborator

These test would fail if ran in wall clock maintenance window. By using fake timers this can be prevented.

Copilot AI review requested due to automatic review settings July 3, 2026 07:07
@FilOzzy FilOzzy added this to FOC Jul 3, 2026
@github-project-automation github-project-automation Bot moved this to 📌 Triage in FOC Jul 3, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR stabilizes data_set_lifecycle_check scheduling tests by pinning the system clock with Vitest fake timers, preventing failures when the suite runs during the app’s maintenance window.

Changes:

  • Enabled vi.useFakeTimers() in the two data_set_lifecycle_check scheduling tests.
  • Fixed the perceived current time via vi.setSystemTime(...) to a known-safe timestamp.

@rjan90 rjan90 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

lgtm,

@github-project-automation github-project-automation Bot moved this from 📌 Triage to ✔️ Approved by reviewer in FOC Jul 3, 2026
@silent-cipher silent-cipher merged commit 207db84 into main Jul 3, 2026
11 checks passed
@silent-cipher silent-cipher deleted the test/use-fake-timers branch July 3, 2026 08:27
@github-project-automation github-project-automation Bot moved this from ✔️ Approved by reviewer to 🎉 Done in FOC Jul 3, 2026
@silent-cipher silent-cipher self-assigned this Jul 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: 🎉 Done

Development

Successfully merging this pull request may close these issues.

4 participants