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

Commit 040368e

Browse files
Make it build
1 parent 9dc07c8 commit 040368e

File tree

7 files changed

+24
-32
lines changed

7 files changed

+24
-32
lines changed

.circleci/config.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ version: 2
22
jobs:
33
MacOS:
44
macos:
5-
xcode: "9.0"
5+
xcode: "9.3.0"
66
steps:
77
- checkout
88
- restore_cache:
@@ -14,6 +14,7 @@ jobs:
1414
brew tap vapor/homebrew-tap
1515
brew install cmysql
1616
brew install ctls
17+
brew install libressl
1718
- run:
1819
name: Build and Run Tests
1920
no_output_timeout: 1800
@@ -30,7 +31,7 @@ jobs:
3031
- .build
3132
Linux:
3233
docker:
33-
- image: brettrtoomey/vapor-ci:0.0.1
34+
- image: nodesvapor/vapor-ci:swift-4.1
3435
steps:
3536
- checkout
3637
- restore_cache:

.swiftlint.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@ included:
22
- Sources
33
function_body_length:
44
warning: 60
5-
variable_name:
5+
identifier_name:
66
min_length:
77
warning: 2
8-
line_length: 80
8+
line_length: 100
99
disabled_rules:
1010
- opening_brace
1111
colon:

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Sugar 🍬
2-
[![Swift Version](https://img.shields.io/badge/Swift-3-brightgreen.svg)](http://swift.org)
3-
[![Vapor Version](https://img.shields.io/badge/Vapor-2-F6CBCA.svg)](http://vapor.codes)
2+
[![Swift Version](https://img.shields.io/badge/Swift-4.1-brightgreen.svg)](http://swift.org)
3+
[![Vapor Version](https://img.shields.io/badge/Vapor-3-30B6FC.svg)](http://vapor.codes)
44
[![Circle CI](https://circleci.com/gh/nodes-vapor/sugar/tree/master.svg?style=shield)](https://circleci.com/gh/nodes-vapor/sugar)
55
[![codebeat badge](https://codebeat.co/badges/54770476-a759-47f8-9372-1009267a56e0)](https://codebeat.co/projects/github-com-nodes-vapor-sugar-master)
66
[![codecov](https://codecov.io/gh/nodes-vapor/sugar/branch/master/graph/badge.svg)](https://codecov.io/gh/nodes-vapor/sugar)
@@ -13,7 +13,7 @@
1313
Update your `Package.swift` file.
1414

1515
```swift
16-
.Package(url: "https://github.com/nodes-vapor/sugar.git", majorVersion: 1)
16+
TODO
1717
```
1818

1919

Sources/Sugar/Helpers/Model.swift

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
import Fluent
2+
import Vapor
3+
14
public extension Model where Database: QuerySupporting {
25
public static func requireFind(
36
_ id: ID,

Tests/LinuxMain.swift

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import XCTest
2+
@testable import SugarTests
23

3-
import SugarTests
4-
5-
var tests = [XCTestCaseEntry]()
6-
tests += SugarTests.allTests()
7-
XCTMain(tests)
4+
XCTMain([
5+
testCase(SugarTests.allTests),
6+
])

Tests/SugarTests/SugarTests.swift

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,14 @@
11
import XCTest
22
@testable import Sugar
33

4-
final class SugarTests: XCTestCase {
5-
func testExample() {
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(Sugar().text, "Hello, World!")
4+
class SugarTests: XCTestCase {
5+
func testExample() throws {
6+
XCTAssertTrue(true)
107
}
118

12-
13-
static var allTests = [
14-
("testExample", testExample),
15-
]
16-
}
9+
static var allTests : [(String, (SugarTests) -> () throws -> Void)] {
10+
return [
11+
("testExample", testExample),
12+
]
13+
}
14+
}

Tests/SugarTests/XCTestManifests.swift

Lines changed: 0 additions & 9 deletions
This file was deleted.

0 commit comments

Comments
 (0)