Skip to content

Commit ab527b3

Browse files
Make cron checks work on v5 (#3875)
1 parent 9522640 commit ab527b3

File tree

13 files changed

+64
-38
lines changed

13 files changed

+64
-38
lines changed

.github/workflows/cron-checks.yml

Lines changed: 13 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -22,23 +22,19 @@ jobs:
2222
matrix:
2323
include:
2424
- ios: 18.5
25-
xcode: 16.4
2625
os: macos-15
2726
device: "iPhone 16 Pro"
2827
setup_runtime: false
2928
- ios: 17.5
30-
xcode: 15.4
31-
os: macos-14
29+
os: macos-15
3230
device: "iPhone 15 Pro"
33-
setup_runtime: false
31+
setup_runtime: true
3432
- ios: 16.4
35-
xcode: 15.3 # fails on 15.4
36-
os: macos-14
33+
os: macos-15
3734
device: "iPhone 14 Pro"
3835
setup_runtime: true
3936
- ios: 15.5
40-
xcode: 15.3 # fails on 15.4
41-
os: macos-14
37+
os: macos-15
4238
device: "iPhone 13 Pro"
4339
setup_runtime: true
4440
fail-fast: false
@@ -47,7 +43,7 @@ jobs:
4743
GITHUB_EVENT: ${{ toJson(github.event) }}
4844
ALLURE_TOKEN: ${{ secrets.ALLURE_TOKEN }}
4945
STREAM_DEMO_APP_SECRET: ${{ secrets.STREAM_DEMO_APP_SECRET }}
50-
XCODE_VERSION: ${{ matrix.xcode }}
46+
XCODE_VERSION: "26.0.1"
5147
IOS_SIMULATOR_DEVICE: "${{ matrix.device }} (${{ matrix.ios }})" # For the Allure report
5248
steps:
5349
- uses: actions/[email protected]
@@ -66,7 +62,7 @@ jobs:
6662
- name: Launch Allure TestOps
6763
run: bundle exec fastlane allure_launch cron:true
6864
- name: Run UI Tests (Debug)
69-
run: bundle exec fastlane test_e2e_mock device:"${{ matrix.device }} (${{ matrix.ios }})"
65+
run: bundle exec fastlane test_e2e_mock device:"${{ env.IOS_SIMULATOR_DEVICE }}"
7066
timeout-minutes: 120
7167
- name: Allure TestOps Upload
7268
if: success() || failure()
@@ -95,29 +91,26 @@ jobs:
9591
matrix:
9692
include:
9793
- ios: 18.5
98-
xcode: 16.4
9994
os: macos-15
10095
device: "iPhone 16 Pro"
10196
setup_runtime: false
10297
- ios: 17.5
10398
xcode: 15.4
104-
os: macos-14
99+
os: macos-15
105100
device: "iPhone 15 Pro"
106-
setup_runtime: false
101+
setup_runtime: true
107102
- ios: 16.4
108-
xcode: 15.3 # fails on 15.4
109-
os: macos-14
103+
os: macos-15
110104
device: "iPhone 14 Pro"
111105
setup_runtime: true
112106
- ios: 15.5
113-
xcode: 15.3 # fails on 15.4
114-
os: macos-14
107+
os: macos-15
115108
device: "iPhone 13 Pro"
116109
setup_runtime: true
117110
fail-fast: false
118111
runs-on: ${{ matrix.os }}
119112
env:
120-
XCODE_VERSION: ${{ matrix.xcode }}
113+
XCODE_VERSION: "26.0.1"
121114
steps:
122115
- uses: actions/[email protected]
123116
- uses: ./.github/actions/bootstrap
@@ -147,10 +140,10 @@ jobs:
147140
fastlane/test_output/logs/*/Diagnostics/simctl_diagnostics/DiagnosticReports/*
148141
149142
build-old-xcode:
150-
name: Build LLC + UI (Xcode 15)
143+
name: Build SDKs (Old Xcode)
151144
runs-on: macos-14
152145
env:
153-
XCODE_VERSION: "15.4"
146+
XCODE_VERSION: "16.1"
154147
steps:
155148
- name: Connect Bot
156149
uses: webfactory/[email protected]

.github/workflows/smoke-checks.yml

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -61,22 +61,21 @@ jobs:
6161
- run: bundle exec fastlane validate_public_interface
6262

6363
build-old-xcode:
64-
name: Build LLC + UI (Xcode 15)
65-
runs-on: macos-15
66-
# if: ${{ github.event.inputs.record_snapshots != 'true' }}
67-
if: false # disable Xcode 15 builds
64+
name: Build SDKs (Old Xcode)
65+
runs-on: macos-14
66+
if: ${{ github.event.inputs.record_snapshots != 'true' }}
6867
env:
69-
XCODE_VERSION: "15.4"
68+
XCODE_VERSION: "16.1"
7069
steps:
7170
- uses: actions/[email protected]
7271
- uses: ./.github/actions/ruby-cache
7372
- name: List Xcode versions
7473
run: mdfind "kMDItemCFBundleIdentifier = 'com.apple.dt.Xcode'"
7574
- name: Build LLC
76-
run: bundle exec fastlane test device:"iPhone 13" build_for_testing:true
75+
run: bundle exec fastlane test device:"iPhone 16 (18.1)" build_for_testing:true
7776
timeout-minutes: 25
7877
- name: Build UI
79-
run: bundle exec fastlane test_ui device:"iPhone 13" build_for_testing:true
78+
run: bundle exec fastlane test_ui device:"iPhone 16 (18.1)" build_for_testing:true
8079
timeout-minutes: 25
8180

8281
test-llc-debug:

DemoApp/Screens/UserProfile/UserProfileViewController.swift

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -298,11 +298,13 @@ class UserProfileViewController: UITableViewController, CurrentChatUserControlle
298298
loadingSpinner.startAnimating()
299299

300300
uploadImageAndUpdateProfile(selectedImage) { [weak self] error in
301-
self?.loadingSpinner.stopAnimating()
302-
if let error = error {
303-
self?.showError(error)
304-
} else {
305-
self?.showSuccess()
301+
Task { @MainActor [weak self] in
302+
self?.loadingSpinner.stopAnimating()
303+
if let error = error {
304+
self?.showError(error)
305+
} else {
306+
self?.showSuccess()
307+
}
306308
}
307309
}
308310
}

Sources/StreamChat/Repositories/ConnectionRepository.swift

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,9 @@ class ConnectionRepository: @unchecked Sendable {
177177
.authenticating:
178178
shouldNotifyConnectionIdWaiters = false
179179
connectionId = nil
180+
@unknown default:
181+
shouldNotifyConnectionIdWaiters = false
182+
connectionId = nil
180183
}
181184

182185
updateConnectionId(

Sources/StreamChat/WebSocketClient/Events/MessageEvents.swift

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
import Foundation
66

77
/// Triggered when a new message is sent to channel.
8-
final public class MessageNewEvent: ChannelSpecificEvent, HasUnreadCount {
8+
public final class MessageNewEvent: ChannelSpecificEvent, HasUnreadCount {
99
/// The user who sent a message.
1010
public let user: ChatUser
1111

@@ -332,19 +332,19 @@ public final class NewMessageErrorEvent: ChannelSpecificEvent {
332332
public final class MessageDeliveredEvent: ChannelSpecificEvent {
333333
/// The user who received the delivered message.
334334
public let user: ChatUser
335-
335+
336336
/// The channel identifier the message was delivered to.
337337
public var cid: ChannelId { channel.cid }
338-
338+
339339
/// The channel the message was delivered to.
340340
public let channel: ChatChannel
341-
341+
342342
/// The event timestamp.
343343
public let createdAt: Date
344-
344+
345345
/// The ID of the last delivered message.
346346
public let lastDeliveredMessageId: MessageId
347-
347+
348348
/// The timestamp when the message was delivered.
349349
public let lastDeliveredAt: Date
350350

Sources/StreamChatUI/ChatChannelList/ChatChannelListVC.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -441,6 +441,8 @@ open class ChatChannelListVC: _ViewController,
441441
shouldHideEmptyView = emptyView.isHidden
442442
isLoading = false
443443
channelListErrorView.show()
444+
@unknown default:
445+
break
444446
}
445447

446448
emptyView.isHidden = shouldHideEmptyView

Sources/StreamChatUI/ChatMessageList/Attachments/File/ChatFileAttachmentListView+ItemView.swift

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,8 @@ extension ChatMessageFileAttachmentListView {
123123
fileSizeLabel.text = content?.downloadingState?.fileProgress
124124
case .downloaded, .downloadingFailed:
125125
fileSizeLabel.text = content?.payload.file.sizeString
126+
@unknown default:
127+
break
126128
}
127129
} else if let uploadState {
128130
switch uploadState {
@@ -132,6 +134,8 @@ extension ChatMessageFileAttachmentListView {
132134
fileSizeLabel.text = L10n.Message.Sending.attachmentUploadingFailed
133135
case .pendingUpload, .uploaded, .unknown:
134136
fileSizeLabel.text = content?.payload.file.sizeString
137+
@unknown default:
138+
break
135139
}
136140
} else {
137141
fileSizeLabel.text = content?.payload.file.sizeString

Sources/StreamChatUI/ChatMessageList/Attachments/UploadingOverlayView.swift

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,8 @@ open class UploadingOverlayView: _View, ThemeProvider {
113113
return .restart
114114
case .uploaded:
115115
return .uploaded
116+
@unknown default:
117+
return nil
116118
}
117119
}
118120
actionButton.isHidden = actionButton.content == nil
@@ -127,6 +129,8 @@ open class UploadingOverlayView: _View, ThemeProvider {
127129
return nil
128130
case .uploadingFailed:
129131
return L10n.Message.Sending.attachmentUploadingFailed
132+
@unknown default:
133+
return nil
130134
}
131135
}
132136
uploadingProgressLabel.isHidden = uploadingProgressLabel.text == nil
@@ -171,6 +175,8 @@ extension LocalAttachmentState {
171175
return "0/\(file.sizeString)"
172176
case .uploaded, .uploadingFailed, .unknown:
173177
return file.sizeString
178+
@unknown default:
179+
return ""
174180
}
175181
}
176182
}
@@ -190,6 +196,8 @@ extension AttachmentDownloadingState {
190196
return file?.progressDescription(for: progress) ?? ""
191197
case .downloaded, .downloadingFailed:
192198
return file?.sizeString ?? ""
199+
@unknown default:
200+
return ""
193201
}
194202
}
195203
}
@@ -203,6 +211,8 @@ extension AttachmentUploadingState {
203211
return "0 / \(file.sizeString)"
204212
case .uploaded, .uploadingFailed, .unknown:
205213
return file.sizeString
214+
@unknown default:
215+
return ""
206216
}
207217
}
208218
}

Sources/StreamChatUI/ChatMessageList/Reactions/ChatMessageReactionsPickerVC.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,7 @@ open class ChatMessageReactionsPickerVC: _ViewController, ThemeProvider, ChatMes
8484
switch change {
8585
case .create, .remove: break
8686
case .update: updateContentIfNeeded()
87+
@unknown default: break
8788
}
8889
}
8990
}

Sources/StreamChatUI/ChatThread/ChatThreadVC.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -451,6 +451,8 @@ open class ChatThreadVC: _ViewController,
451451
listChange = .update(item, index: indexPath)
452452
case let .remove(item):
453453
listChange = .remove(item, index: indexPath)
454+
@unknown default:
455+
return
454456
}
455457

456458
updateMessages(with: [listChange])

0 commit comments

Comments
 (0)