Skip to content

Reduce tolerance for nanoseconds - #5

Merged
atdrendel merged 2 commits into
mainfrom
reduce-tolerance-for-nanoseconds
Apr 30, 2026
Merged

Reduce tolerance for nanoseconds#5
atdrendel merged 2 commits into
mainfrom
reduce-tolerance-for-nanoseconds

Conversation

@atdrendel

Copy link
Copy Markdown
Contributor

No description provided.

CopilotAI review requested due to automatic review settings April 30, 2026 22:49
@atdrendel
atdrendel merged commit 9b03fa8 into mainApr 30, 2026
3 checks passed
@atdrendel
atdrendel deleted the reduce-tolerance-for-nanoseconds branch April 30, 2026 22:49

CopilotAI left a comment

Copy link
Copy Markdown

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 tightens DispatchTimer’s default scheduling tolerance for .nanoseconds intervals and adds unit tests to lock in the new behavior, alongside updating the CI workflow environment.

Changes:

  • Update DispatchTimer.defaultTolerance(_:) so positive .nanoseconds intervals map to .nanoseconds(0) (and non-positive remain .never).
  • Add new XCTest cases covering defaultTolerance behavior for .nanoseconds and .never.
  • Update GitHub Actions CI runner / checkout version / Xcode selection.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

FileDescription
Sources/DispatchTimer/DispatchTimer.swiftChanges default tolerance handling for .nanoseconds and adjusts extension visibility to enable testing.
Tests/DispatchTimerTests/DispatchTimerTests.swiftAdds coverage for default tolerance behavior and updates Linux allTests.
.github/workflows/ci.ymlChanges macOS runner, updates checkout action, and pins an Xcode selection.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@atdrendel