Modernize NerdzPinView (3.2.0): tests, CI, DocC, docs, underline fix - #4
Merged
Merged
Conversation
Add NerdzPinViewTests with 47 tests across text position/range/selection math and per-state appearance config resolution for the bordered, underline, and one-time item views. Logic layer is near-fully covered; the UIKit view/rendering layer is intentionally left for snapshot tests.
Run build and test on a macOS runner via xcodebuild against an iOS Simulator (public repo, so macOS minutes are free). The library depends on UIKit and cannot build on Linux. The test job derives an available iPhone simulator UDID at runtime so it survives runner image changes.
Correct the README Swift badge (it claimed 5.9 and rendered 5.1 while the package requires Swift 6.0), add a Requirements section stating iOS 16 and Xcode 16, remove a duplicate Requirements section, and add a Keep a Changelog CHANGELOG.md starting at 3.2.0.
Replace the leftover PinViewDemo project name in file headers with NerdzPinView across nine source files.
Add a Documentation.docc catalog (landing page with Topics, a Getting Started article, and a UIKit usage article) and /// doc comments to every public symbol across the module. docbuild is warning free. No code or signature changes.
…ayoutConfig The LayoutConfig initializer accepted an underlineHeight argument that was never stored, so setting it had no effect. Underline height is controlled by AppearanceConfig via getUnderlineHeight(for:). Remove the dead parameter and its doc, and add a LayoutConfig round-trip test guarding that every initializer argument lands in a stored property. Runtime behavior unchanged.
RomanKovalchukDev
left a comment
Owner
Author
There was a problem hiding this comment.
See inline comments.
Add a dedicated SwiftUIUsage article symmetric to UIKitUsage, slim GettingStarted to installation plus next-step pointers, and wire the new article into the landing page Topics. Remove low-value doc comments from the PinCode action typealiases.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Modernizes NerdzPinView for the 3.2.0 release: a real test suite, CI, accurate docs, DocC, and a small bug fix. No runtime behavior changes for existing SwiftUI or UIKit usage. One source level cleanup is called out under Removed.
Added
NerdzPinViewTests) with 48 tests across 19 suites covering the logic layer: text position, range, and selection math, plus per state appearance config resolution for the bordered, underline, and one time item views.CHANGELOG.mdin Keep a Changelog format, starting history at 3.2.0.Changed
PinViewDemoproject name in file headers across nine source files.Removed
underlineHeightparameter fromUnderlineItemView.LayoutConfig.init. The parameter was never stored and had no effect (underline height is controlled byUnderlineItemView.AppearanceConfigviagetUnderlineHeight(for:)). Runtime behavior is unchanged. Call sites that passedunderlineHeight:to the layout initializer should remove that argument and set the height on the appearance config instead.Notes