Fix OmniTests: pass decisionId to UnfinalizedDose#77
Conversation
…ests
UnfinalizedDose's bolus initializer gained a required decisionId: UUID?
parameter; the source call sites were updated but
testBolusFinishedEarlyOnPodIsMarkedNonMutable was missed, so the
OmniTests target failed to compile ("missing argument for parameter
'decisionId'"). Passes decisionId: nil, matching the other test/source
call sites.
loopandlearn/OmnipodKit loop-next-dev HEAD (f529581a) has a test that fails to compile -- UnfinalizedDose's bolus init now requires decisionId but PodCommsSessionTests wasn't updated, breaking the CI `test` step. Points OmnipodKit at loopkitdev/OmnipodKit loop-next-dev @ d03b34d (f529581a + the one-line test fix); upstream PR is loopandlearn/OmnipodKit#77. Revert to loopandlearn once that merges.
CryptoSwift 1.9.0 removed its `Data.bytes -> [UInt8]` extension (renamed to `byteArray`). On the Xcode 26 SDK, `data.bytes` then resolves to Foundation's new native `Data.bytes`, which returns a `RawSpan` - breaking every crypto call site with errors like: Cannot convert value of type 'RawSpan' to expected argument type 'Array<UInt8>' Value of type 'RawSpan' has no member 'toHexString' Builds pinned to CryptoSwift <= 1.8.5 are unaffected, so this only bites users whose package resolution floats up to 1.9.0/1.10.0 (e.g. after 'Update to Latest Package Versions'). Replace `<data>.bytes` with `Array(<data>)`, which yields the same [UInt8] and compiles against every CryptoSwift version (and doesn't depend on CryptoSwift at all). Verified building OmnipodKit against CryptoSwift 1.10.0 on Xcode 26.5.
Test Summary✅ successful test
BackgroundNote: this PR is using loopkitdev:loop-next-dev as the source branch and that branch has 2 commits: This PR encompasses both PR #77 and PR #78. Confirm this in a local clone, and then merge #78 first followed by #77. I expected this PR to update after merging PR #78 and just show the one commit to add decisionID to OmniTests. Work in local cloneStart with LoopWorkspace next-dev brach That branch references the source branch in the PR. If I switch to the target branch in this PR, OmniTests cannot be built:
I confirmed locally that the only difference between loopandlearn:loop-next-dev and loopkitdev:loop-next-dev is the following: |
marionbarker
left a comment
There was a problem hiding this comment.
Approve by code review and test.

Summary
UnfinalizedDose's bolus initializer now requiresdecisionId: UUID?, butOmniTests/PodCommsSessionTests.swift(testBolusFinishedEarlyOnPodIsMarkedNonMutable) still calls it without one, so the OmniTests target fails to compile:The app/source call sites were already updated (e.g.
UnfinalizedDose(decisionId: nil, bolusAmount: ...)); this just brings the test in line. Surfaces in CItest(not plainbuild, which doesn't compile the test target).Change
One line — add
decisionId: nil,to the test's bolus construction.Test plan
OmniTeststarget compilestestBolusFinishedEarlyOnPodIsMarkedNonMutablepasses