Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
the-freshlord committed Jan 19, 2020
1 parent 4c7ba7f commit 1955505
Show file tree
Hide file tree
Showing 6 changed files with 74 additions and 0 deletions.
6 changes: 6 additions & 0 deletions .gitignore
@@ -0,0 +1,6 @@
.DS_Store
/.build
Package.resolved
.swiftpm
/*.xcodeproj
xcuserdata/
34 changes: 34 additions & 0 deletions Package.swift
@@ -0,0 +1,34 @@
/**
* CNAME file generator plugin for Publish
* Copyright (c) Manny Guerrero 2020
* MIT license, see LICENSE file for details
*/

// swift-tools-version:5.1
// The swift-tools-version declares the minimum version of Swift required to build this package.

import PackageDescription

let package = Package(
name: "CNAMEPublishPlugin",
products: [
// Products define the executables and libraries produced by a package, and make them visible to other packages.
.library(
name: "CNAMEPublishPlugin",
targets: ["CNAMEPublishPlugin"]),
],
dependencies: [
// Dependencies declare other packages that this package depends on.
// .package(url: /* package url */, from: "1.0.0"),
],
targets: [
// Targets are the basic building blocks of a package. A target can define a module or a test suite.
// Targets can depend on other targets in this package, and on products in packages which this package depends on.
.target(
name: "CNAMEPublishPlugin",
dependencies: []),
.testTarget(
name: "CNAMEPublishPluginTests",
dependencies: ["CNAMEPublishPlugin"]),
]
)
3 changes: 3 additions & 0 deletions Sources/CNAMEPublishPlugin/CNAMEPublishPlugin.swift
@@ -0,0 +1,3 @@
struct CNAMEPublishPlugin {
var text = "Hello, World!"
}
15 changes: 15 additions & 0 deletions Tests/CNAMEPublishPluginTests/CNAMEPublishPluginTests.swift
@@ -0,0 +1,15 @@
import XCTest
@testable import CNAMEPublishPlugin

final class CNAMEPublishPluginTests: XCTestCase {
func testExample() {
// This is an example of a functional test case.
// Use XCTAssert and related functions to verify your tests produce the correct
// results.
XCTAssertEqual(CNAMEPublishPlugin().text, "Hello, World!")
}

static var allTests = [
("testExample", testExample),
]
}
9 changes: 9 additions & 0 deletions Tests/CNAMEPublishPluginTests/XCTestManifests.swift
@@ -0,0 +1,9 @@
import XCTest

#if !canImport(ObjectiveC)
public func allTests() -> [XCTestCaseEntry] {
return [
testCase(CNAMEPublishPluginTests.allTests),
]
}
#endif
7 changes: 7 additions & 0 deletions Tests/LinuxMain.swift
@@ -0,0 +1,7 @@
import XCTest

import CNAMEPublishPluginTests

var tests = [XCTestCaseEntry]()
tests += CNAMEPublishPluginTests.allTests()
XCTMain(tests)

0 comments on commit 1955505

Please sign in to comment.