-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Create GraphQL library from SwiftPM package 📦
- Loading branch information
Showing
5 changed files
with
56 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
// swift-tools-version:4.2 | ||
|
||
import PackageDescription | ||
|
||
let package = Package( | ||
name: "GraphQL", | ||
products: [ | ||
.library( | ||
name: "GraphQL", | ||
targets: ["GraphQL"] | ||
) | ||
], | ||
dependencies: [], | ||
targets: [ | ||
.target( | ||
name: "GraphQL", | ||
dependencies: [] | ||
), | ||
.testTarget( | ||
name: "GraphQLTests", | ||
dependencies: ["GraphQL"] | ||
) | ||
] | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
struct GraphQL {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
import XCTest | ||
@testable import GraphQL | ||
|
||
final class GraphQLTests: XCTestCase { | ||
func testExample() { | ||
XCTAssertTrue(!false) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import XCTest | ||
|
||
extension GraphQLTests { | ||
static let __allTests = [ | ||
("testExample", testExample), | ||
] | ||
} | ||
|
||
#if !os(macOS) | ||
public func __allTests() -> [XCTestCaseEntry] { | ||
return [ | ||
testCase(GraphQLTests.__allTests), | ||
] | ||
} | ||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
import XCTest | ||
|
||
import GraphQLTests | ||
|
||
var tests = [XCTestCaseEntry]() | ||
tests += GraphQLTests.__allTests() | ||
|
||
XCTMain(tests) |