Skip to content

Commit 50a17a9

Browse files
committed
Add Test action
1 parent 40eff2a commit 50a17a9

2 files changed

Lines changed: 19 additions & 2 deletions

File tree

.github/workflows/test.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
name: Test
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
8+
jobs:
9+
test:
10+
name: Run tests
11+
runs-on: macOS-latest
12+
13+
steps:
14+
- name: Checkout
15+
uses: actions/checkout@master
16+
- name: Test
17+
run: xcodebuild -project CameraController.xcworkspace -scheme CameraController -sdk macos test | xcpretty

CameraController/Devices/DeviceManager.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ class DevicesManager: ObservableObject {
5959
}
6060

6161
@objc
62-
private func deviceAdded(notif: NSNotification) {
62+
func deviceAdded(notif: NSNotification) {
6363
guard let device = notif.object as? AVCaptureDevice else {
6464
return
6565
}
@@ -68,7 +68,7 @@ class DevicesManager: ObservableObject {
6868
}
6969

7070
@objc
71-
private func deviceRemoved(notif: NSNotification) {
71+
func deviceRemoved(notif: NSNotification) {
7272
guard let device = notif.object as? AVCaptureDevice else {
7373
return
7474
}

0 commit comments

Comments
 (0)