This repository was archived by the owner on May 8, 2026. It is now read-only.
File tree Expand file tree Collapse file tree
Networking/Tests/NetworkingTests/Mocks Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2929 - name : Set Xcode version
3030 uses : maxim-lobanov/setup-xcode@v1
3131 with :
32- xcode-version : ' 16.2 '
32+ xcode-version : ' 26.0 '
3333 - name : Set default scheme
3434 run : |
3535 scheme_list=$(xcodebuild -list -json | tr -d "\n")
Original file line number Diff line number Diff line change 66//
77
88/// [Source](https://hn.algolia.com/api)
9- struct AlgoliaItemDTO : Decodable {
9+ struct AlgoliaItemDTO : Decodable , Sendable {
1010
1111 // MARK: Properties
1212
Original file line number Diff line number Diff line change @@ -54,12 +54,7 @@ struct DebugView: View {
5454 }
5555 }
5656 }
57- . searchable (
58- text: $text,
59- placement: . navigationBarDrawer(
60- displayMode: . always
61- )
62- )
57+ . searchable ( text: $text)
6358 }
6459 }
6560 . navigationTitle ( String ( " Requests " ) )
Original file line number Diff line number Diff line change @@ -22,7 +22,16 @@ struct CommentRowView<Model: CommentRowViewModelProtocol>: View {
2222 . cornerRadius ( 1.5 )
2323 . foregroundColor ( lineColor)
2424 . frame ( width: 3 )
25- . padding ( . vertical, 5 )
25+ . padding (
26+ . vertical,
27+ {
28+ if #available( iOS 26 . 0 , * ) {
29+ . zero
30+ } else {
31+ 5
32+ }
33+ } ( )
34+ )
2635 }
2736 VStack ( alignment: . leading, spacing: 10 ) {
2837 HStack {
@@ -56,7 +65,16 @@ struct CommentRowView<Model: CommentRowViewModelProtocol>: View {
5665 . contentShape ( Rectangle ( ) )
5766 . opacity ( opacity)
5867 . padding ( . leading, leadingPadding)
59- . padding ( . vertical, 5 )
68+ . padding (
69+ . vertical,
70+ {
71+ if #available( iOS 26 . 0 , * ) {
72+ . zero
73+ } else {
74+ 5
75+ }
76+ } ( )
77+ )
6078 }
6179}
6280
Original file line number Diff line number Diff line change @@ -92,7 +92,16 @@ struct ItemRowView<Model: ItemRowViewModelProtocol>: View {
9292 }
9393 }
9494 . opacity ( model. isRead ? 0.7 : 1 )
95- . padding ( . vertical, 5 )
95+ . padding (
96+ . vertical,
97+ {
98+ if #available( iOS 26 . 0 , * ) {
99+ . zero
100+ } else {
101+ 5
102+ }
103+ } ( )
104+ )
96105 }
97106}
98107
Original file line number Diff line number Diff line change @@ -114,11 +114,20 @@ struct ItemView<Model: ItemViewModelProtocol>: View {
114114 }
115115 }
116116 . alert ( error: $model. error)
117+ . background ( Color ( . systemBackground) )
117118 . listStyle ( . plain)
118119 . navigationBarTitleDisplayMode ( . inline)
119120 . navigationDestination ( item: $model. secondaryItem) { item in
120121 ItemView < ItemViewModel > ( model: ItemViewModel ( item: item) )
121- . toolbarRole ( . editor)
122+ . toolbarRole (
123+ {
124+ if #available( iOS 26 . 0 , * ) {
125+ . navigationStack
126+ } else {
127+ . editor
128+ }
129+ } ( )
130+ )
122131 }
123132 . navigationTitle ( model. title)
124133 . onAppear {
Original file line number Diff line number Diff line change @@ -30,8 +30,9 @@ actor URLSessionMock: URLSessionProtocol {
3030 delegate: ( any URLSessionTaskDelegate ) ?
3131 ) async throws -> ( Data , URLResponse ) {
3232 dataCallCount += 1
33+ let _dataStub = try #require( _dataStub)
3334
34- return try await ( #require ( _dataStub) ) ( request, delegate)
35+ return try await _dataStub ( request, delegate)
3536 }
3637
3738 func dataStub( _ dataStub: DataStub ? ) {
You can’t perform that action at this time.
0 commit comments