Skip to content

Commit 017bdb8

Browse files
authored
Test infrastructure (#52)
* Adding tests target * Adding test plan * Fixing deps * Add test workflow * Add config * More * Change workflow * Add test step to release * Signing changes * Signing changes * Remove 11.4 specific test * More signing
1 parent 99c8562 commit 017bdb8

File tree

11 files changed

+420
-73
lines changed

11 files changed

+420
-73
lines changed

.github/workflows/release.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,20 @@ on:
55
tags:
66
- '*'
77
jobs:
8+
test:
9+
runs-on: macOS-latest
10+
timeout-minutes: 10
11+
steps:
12+
- uses: actions/checkout@v1
13+
- name: Setup Signing
14+
env:
15+
SIGNING_DATA: ${{ secrets.SIGNING_DATA }}
16+
SIGNING_PASSWORD: ${{ secrets.SIGNING_PASSWORD }}
17+
HOST_PROFILE_DATA: ${{ secrets.HOST_PROFILE_DATA }}
18+
AGENT_PROFILE_DATA: ${{ secrets.AGENT_PROFILE_DATA }}
19+
run: ./.github/scripts/signing.sh
20+
- name: Test
21+
run: xcrun xcodebuild test -project Secretive.xcodeproj -scheme Secretive
822
build:
923
runs-on: macOS-latest
1024
timeout-minutes: 10

.github/workflows/test.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
name: Test
2+
3+
on: push
4+
jobs:
5+
test:
6+
runs-on: macOS-latest
7+
timeout-minutes: 10
8+
steps:
9+
- uses: actions/checkout@v1
10+
- name: Setup Signing
11+
env:
12+
SIGNING_DATA: ${{ secrets.SIGNING_DATA }}
13+
SIGNING_PASSWORD: ${{ secrets.SIGNING_PASSWORD }}
14+
HOST_PROFILE_DATA: ${{ secrets.HOST_PROFILE_DATA }}
15+
AGENT_PROFILE_DATA: ${{ secrets.AGENT_PROFILE_DATA }}
16+
run: ./.github/scripts/signing.sh
17+
- name: Test
18+
run: xcrun xcodebuild test -project Secretive.xcodeproj -scheme Secretive

Config/Secretive.xctestplan

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
{
2+
"configurations" : [
3+
{
4+
"id" : "5896AE5A-6D5A-48D3-837B-668B646A3273",
5+
"name" : "Configuration 1",
6+
"options" : {
7+
8+
}
9+
}
10+
],
11+
"defaultOptions" : {
12+
13+
},
14+
"testTargets" : [
15+
{
16+
"parallelizable" : true,
17+
"target" : {
18+
"containerPath" : "container:Secretive.xcodeproj",
19+
"identifier" : "50617DAF23FCE4AB0099B055",
20+
"name" : "SecretKitTests"
21+
}
22+
},
23+
{
24+
"parallelizable" : true,
25+
"target" : {
26+
"containerPath" : "container:Secretive.xcodeproj",
27+
"identifier" : "5099A073240242BA0062B6F2",
28+
"name" : "SecretAgentKitTests"
29+
}
30+
},
31+
{
32+
"parallelizable" : true,
33+
"target" : {
34+
"containerPath" : "container:Secretive.xcodeproj",
35+
"identifier" : "50617D9323FCE48E0099B055",
36+
"name" : "SecretiveTests"
37+
}
38+
}
39+
],
40+
"version" : 1
41+
}

SecretAgentKitTests/SecretAgentKitTests.swift

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -11,24 +11,9 @@ import XCTest
1111

1212
class SecretAgentKitTests: XCTestCase {
1313

14-
override func setUpWithError() throws {
15-
// Put setup code here. This method is called before the invocation of each test method in the class.
16-
}
17-
18-
override func tearDownWithError() throws {
19-
// Put teardown code here. This method is called after the invocation of each test method in the class.
20-
}
21-
2214
func testExample() throws {
2315
// This is an example of a functional test case.
2416
// Use XCTAssert and related functions to verify your tests produce the correct results.
2517
}
2618

27-
func testPerformanceExample() throws {
28-
// This is an example of a performance test case.
29-
self.measure {
30-
// Put the code you want to measure the time of here.
31-
}
32-
}
33-
3419
}

SecretKitTests/SecretKitTests.swift

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,4 @@ class SecretKitTests: XCTestCase {
2424
// Use XCTAssert and related functions to verify your tests produce the correct results.
2525
}
2626

27-
func testPerformanceExample() {
28-
// This is an example of a performance test case.
29-
self.measure {
30-
// Put the code you want to measure the time of here.
31-
}
32-
}
33-
3427
}

0 commit comments

Comments
 (0)