Skip to content
This repository was archived by the owner on May 25, 2024. It is now read-only.

Commit 9518c80

Browse files
authored
Update Tests (#47)
* Update build workflow and add TestPlan * Fix compile error on Test target * Fix * Update * Update simulator version * Mock EmotionDetector * Revert "Mock EmotionDetector" This reverts commit eec6af4. * For CI * Fix build args * Avoid Bundle.module on CI * Fix * Fix gitignore * Do test as well
1 parent 01fed3b commit 9518c80

File tree

29 files changed

+810
-171
lines changed

29 files changed

+810
-171
lines changed

.github/workflows/build.yml

+8-5
Original file line numberDiff line numberDiff line change
@@ -9,18 +9,21 @@ on:
99

1010
defaults:
1111
run:
12-
working-directory: ./ios
12+
working-directory: ./
1313

1414
jobs:
1515
test:
1616
name: "Build iOSApp"
17-
runs-on: macos-12
17+
runs-on: macos-13
1818
steps:
1919
- uses: actions/checkout@v3
2020
- uses: maxim-lobanov/setup-xcode@v1
2121
with:
22-
xcode-version: latest-stable
23-
- name: Build and Test
22+
xcode-version: latest-stable
23+
- name: "Install xcbeautify"
24+
run: brew install xcbeautify
25+
- name: "Build and Test"
26+
working-directory: ios-dev
2427
run: |
2528
set -o pipefail
26-
xcodebuild -project ios.xcodeproj -scheme ios build -destination 'platform=iOS Simulator,name=iPhone 13' | bundle exec xcpretty
29+
xcodebuild -project ios-dev.xcodeproj -scheme ios-dev build test -destination 'platform=iOS Simulator,name=iPhone 14' "OTHER_SWIFT_FLAGS=-D CI" | xcbeautify

.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,8 @@ doc/api/
3131

3232

3333
GoogleService-Info.plist
34+
!ios-dev/ios-dev/GoogleService-Info.plist
35+
3436
google-services.json
3537

3638
*.mlpackage
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,92 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<Scheme
3+
LastUpgradeVersion = "1430"
4+
version = "1.7">
5+
<BuildAction
6+
parallelizeBuildables = "YES"
7+
buildImplicitDependencies = "YES">
8+
<BuildActionEntries>
9+
<BuildActionEntry
10+
buildForTesting = "YES"
11+
buildForRunning = "YES"
12+
buildForProfiling = "YES"
13+
buildForArchiving = "YES"
14+
buildForAnalyzing = "YES">
15+
<BuildableReference
16+
BuildableIdentifier = "primary"
17+
BlueprintIdentifier = "App"
18+
BuildableName = "App"
19+
BlueprintName = "App"
20+
ReferencedContainer = "container:">
21+
</BuildableReference>
22+
</BuildActionEntry>
23+
<BuildActionEntry
24+
buildForTesting = "YES"
25+
buildForRunning = "YES"
26+
buildForProfiling = "NO"
27+
buildForArchiving = "NO"
28+
buildForAnalyzing = "YES">
29+
<BuildableReference
30+
BuildableIdentifier = "primary"
31+
BlueprintIdentifier = "AppTests"
32+
BuildableName = "AppTests"
33+
BlueprintName = "AppTests"
34+
ReferencedContainer = "container:">
35+
</BuildableReference>
36+
</BuildActionEntry>
37+
</BuildActionEntries>
38+
</BuildAction>
39+
<TestAction
40+
buildConfiguration = "Debug"
41+
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
42+
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
43+
shouldUseLaunchSchemeArgsEnv = "YES"
44+
shouldAutocreateTestPlan = "YES">
45+
<Testables>
46+
<TestableReference
47+
skipped = "NO">
48+
<BuildableReference
49+
BuildableIdentifier = "primary"
50+
BlueprintIdentifier = "AppTests"
51+
BuildableName = "AppTests"
52+
BlueprintName = "AppTests"
53+
ReferencedContainer = "container:">
54+
</BuildableReference>
55+
</TestableReference>
56+
</Testables>
57+
</TestAction>
58+
<LaunchAction
59+
buildConfiguration = "Debug"
60+
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
61+
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
62+
launchStyle = "0"
63+
useCustomWorkingDirectory = "NO"
64+
ignoresPersistentStateOnLaunch = "NO"
65+
debugDocumentVersioning = "YES"
66+
debugServiceExtension = "internal"
67+
allowLocationSimulation = "YES">
68+
</LaunchAction>
69+
<ProfileAction
70+
buildConfiguration = "Release"
71+
shouldUseLaunchSchemeArgsEnv = "YES"
72+
savedToolIdentifier = ""
73+
useCustomWorkingDirectory = "NO"
74+
debugDocumentVersioning = "YES">
75+
<MacroExpansion>
76+
<BuildableReference
77+
BuildableIdentifier = "primary"
78+
BlueprintIdentifier = "App"
79+
BuildableName = "App"
80+
BlueprintName = "App"
81+
ReferencedContainer = "container:">
82+
</BuildableReference>
83+
</MacroExpansion>
84+
</ProfileAction>
85+
<AnalyzeAction
86+
buildConfiguration = "Debug">
87+
</AnalyzeAction>
88+
<ArchiveAction
89+
buildConfiguration = "Release"
90+
revealArchiveInOrganizer = "YES">
91+
</ArchiveAction>
92+
</Scheme>

Packages/App/Package.resolved

+9
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,15 @@
1818
"version" : "0.9.1"
1919
}
2020
},
21+
{
22+
"identity" : "floatingactionbutton",
23+
"kind" : "remoteSourceControl",
24+
"location" : "https://github.com/fummicc1/FloatingActionButton",
25+
"state" : {
26+
"revision" : "3af891990e42b5288dcb60565527009e28265bd6",
27+
"version" : "0.0.2"
28+
}
29+
},
2130
{
2231
"identity" : "moya",
2332
"kind" : "remoteSourceControl",
+1-8
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,4 @@
11
import XCTest
22
@testable import App
33

4-
final class AppTests: XCTestCase {
5-
func testExample() throws {
6-
// This is an example of a functional test case.
7-
// Use XCTAssert and related functions to verify your tests produce the correct
8-
// results.
9-
XCTAssertEqual(App().text, "Hello, World!")
10-
}
11-
}
4+
final class AppTests: XCTestCase {}

0 commit comments

Comments
 (0)