Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
  • Loading branch information
onmyway133 committed Jan 11, 2020
1 parent d63a350 commit 8033a63
Show file tree
Hide file tree
Showing 8 changed files with 226 additions and 398 deletions.
7 changes: 7 additions & 0 deletions .swiftpm/xcode/package.xcworkspace/contents.xcworkspacedata

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

21 changes: 14 additions & 7 deletions Example/TestApp/TestApp.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
archiveVersion = 1;
classes = {
};
objectVersion = 50;
objectVersion = 52;
objects = {

/* Begin PBXBuildFile section */
Expand All @@ -14,6 +14,7 @@
D25F73FE23CA7BD8003CCD9E /* Preview Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = D25F73FD23CA7BD8003CCD9E /* Preview Assets.xcassets */; };
D25F740123CA7BD8003CCD9E /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = D25F73FF23CA7BD8003CCD9E /* LaunchScreen.storyboard */; };
D25F741D23CA7C00003CCD9E /* TestAppTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = D25F741C23CA7C00003CCD9E /* TestAppTests.swift */; };
D25F743D23CA8131003CCD9E /* Spek in Frameworks */ = {isa = PBXBuildFile; productRef = D25F743C23CA8131003CCD9E /* Spek */; };
/* End PBXBuildFile section */

/* Begin PBXContainerItemProxy section */
Expand All @@ -38,7 +39,7 @@
D25F741A23CA7C00003CCD9E /* TestAppTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = TestAppTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
D25F741C23CA7C00003CCD9E /* TestAppTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TestAppTests.swift; sourceTree = "<group>"; };
D25F741E23CA7C00003CCD9E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
D25F742B23CA7D0D003CCD9E /* Spek */ = {isa = PBXFileReference; lastKnownFileType = folder; name = Spek; path = ../..; sourceTree = "<group>"; };
D25F743923CA811D003CCD9E /* Spek */ = {isa = PBXFileReference; lastKnownFileType = folder; name = Spek; path = ../..; sourceTree = "<group>"; };
/* End PBXFileReference section */

/* Begin PBXFrameworksBuildPhase section */
Expand All @@ -53,6 +54,7 @@
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
D25F743D23CA8131003CCD9E /* Spek in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand All @@ -62,7 +64,7 @@
D25F73E823CA7BD5003CCD9E = {
isa = PBXGroup;
children = (
D25F742B23CA7D0D003CCD9E /* Spek */,
D25F743923CA811D003CCD9E /* Spek */,
D25F73F323CA7BD5003CCD9E /* TestApp */,
D25F741B23CA7C00003CCD9E /* TestAppTests */,
D25F73F223CA7BD5003CCD9E /* Products */,
Expand Down Expand Up @@ -148,11 +150,12 @@
buildRules = (
);
dependencies = (
D25F742D23CA7D28003CCD9E /* PBXTargetDependency */,
D25F743B23CA812C003CCD9E /* PBXTargetDependency */,
D25F742023CA7C00003CCD9E /* PBXTargetDependency */,
);
name = TestAppTests;
packageProductDependencies = (
D25F743C23CA8131003CCD9E /* Spek */,
);
productName = TestAppTests;
productReference = D25F741A23CA7C00003CCD9E /* TestAppTests.xctest */;
Expand Down Expand Up @@ -243,9 +246,9 @@
target = D25F73F023CA7BD5003CCD9E /* TestApp */;
targetProxy = D25F741F23CA7C00003CCD9E /* PBXContainerItemProxy */;
};
D25F742D23CA7D28003CCD9E /* PBXTargetDependency */ = {
D25F743B23CA812C003CCD9E /* PBXTargetDependency */ = {
isa = PBXTargetDependency;
productRef = D25F742C23CA7D28003CCD9E /* Spek */;
productRef = D25F743A23CA812C003CCD9E /* Spek */;
};
/* End PBXTargetDependency section */

Expand Down Expand Up @@ -488,7 +491,11 @@
/* End XCConfigurationList section */

/* Begin XCSwiftPackageProductDependency section */
D25F742C23CA7D28003CCD9E /* Spek */ = {
D25F743A23CA812C003CCD9E /* Spek */ = {
isa = XCSwiftPackageProductDependency;
productName = Spek;
};
D25F743C23CA8131003CCD9E /* Spek */ = {
isa = XCSwiftPackageProductDependency;
productName = Spek;
};
Expand Down
4 changes: 4 additions & 0 deletions Example/TestApp/TestAppTests/TestAppTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ class TestAppTests: XCTestCase {
It("should add correctly") {
XCTAssertTrue(1 + 1 == 2)
}

It("should fail") {
XCTFail()
}
}
}
}
Expand Down
17 changes: 13 additions & 4 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,29 @@ let package = Package(
dependencies: [],
targets: {
var mutableTargets: [Target] = []
/*
#if os(macOS)
mutableTargets.append(contentsOf: [
.target(name: "SpekHelper", dependencies: []),
.target(name: "Spek", dependencies: ["SpekHelper"])
.target(name: "Spek", dependencies: ["SpekHelper"], exclude: [
"Sources/Spek/SpekTestCase"
])
])
#else
mutableTargets.append(
.target(name: "Spek", dependencies: [])
.target(name: "Spek", dependencies: [], exclude: [
"Sources/Spek/SpekTestCase"
])
)
#endif
*/

mutableTargets.append(
mutableTargets.append(contentsOf: [
.target(name: "Spek", dependencies: [], exclude: [
"Sources/Spek/SpekTestCase"
]),
.testTarget(name: "SpekTests", dependencies: ["Spek"])
)
])

return mutableTargets
}(),
Expand Down
5 changes: 4 additions & 1 deletion Sources/Spek/SpekTestCase.swift
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
// Created by khoa on 11/01/2020.
//

/*

#if canImport(XCTest)

import XCTest
Expand All @@ -23,6 +25,7 @@ open class SpekTestCase: SpekHelperTestCase {
#if canImport(SpekHelper)

override class func spek_testMethodSelectors() -> [SpekSelector] {
let _ = addInstanceMethod()
return [
SpekSelector(selector: Selector("testABC"))
]
Expand All @@ -45,4 +48,4 @@ open class SpekTestCase: SpekHelperTestCase {

#endif


*/
Loading

0 comments on commit 8033a63

Please sign in to comment.