Skip to content

Commit

Permalink
Prepare release 0.6.1
Browse files Browse the repository at this point in the history
  • Loading branch information
dehesa committed Sep 21, 2020
1 parent a62520b commit 4fb8c17
Show file tree
Hide file tree
Showing 43 changed files with 25 additions and 40 deletions.
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ A clear and concise description of what you expected to happen.

## System
- OS: [e.g. macOS 11, iOS 14]
- Conbini: [e.g. 0.7.0]
- Conbini: [e.g. 0.6.1]
You can check this in your SPM `Package.swift` file (or `Package.resolved` file). Alternatively, go to Xcode's Source Control Navigator (`⌘+2`) and click on `Conbini`.

## Additional context
Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/question.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,5 @@ Add any other context about the question here.
## System
Delete section if not applicable
- OS: [e.g. macOS 11, iOS 14]
- Conbini: [e.g. 0.7.0]
- Conbini: [e.g. 0.6.1]
You can check this in your SPM `Package.swift` file (or `Package.resolved` file). Alternatively, go to Xcode's Source Control Navigator (`⌘+2`) and click on `Conbini`.
9 changes: 6 additions & 3 deletions Package.swift
Original file line number Diff line number Diff line change
@@ -1,17 +1,20 @@
// swift-tools-version:5.1
import PackageDescription

let package = Package(
var package = Package(
name: "Conbini",
platforms: [
.macOS(.v10_15), .iOS(.v13), .tvOS(.v13), .watchOS(.v6)
],
products: [
.library(name: "Conbini", targets: ["Conbini"]),
.library(name: "ConbiniForTesting", targets: ["ConbiniForTesting"])
],
dependencies: [],
targets: [
.target(name: "Conbini", dependencies: [], path: "sources"),
.testTarget(name: "ConbiniTests", dependencies: ["Conbini"], path: "tests"),
.target(name: "Conbini", path: "sources/runtime"),
.target(name: "ConbiniForTesting", path: "sources/testing"),
.testTarget(name: "ConbiniTests", dependencies: ["Conbini"], path: "tests/runtime"),
.testTarget(name: "ConbiniForTestingTests", dependencies: ["Conbini", "ConbiniForTesting"], path: "tests/testing"),
]
)
15 changes: 14 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,22 @@ import PackageDescription
let package = Package(
/* Your package name, supported platforms, and generated products go here */
dependencies: [
.package(url: "https://github.com/dehesa/Conbini.git", from: "0.7.0")
.package(url: "https://github.com/dehesa/Conbini.git", from: "0.6.1")
],
targets: [
.target(name: /* Your target name here */, dependencies: ["Conbini"])
]
)
```

If you want to use Conbini's [testing](#testing) extension, you need to define the `CONBINI_FOR_TESTING` flag on your SPM targets or testing targets. Conbini testing extensions require `XCTest`, which is not available in runtime on some platforms (such as watchOS), or you may not want to link to such dynamic library (e.g. when building command-line tools).

```swift
targets: [
.testTarget(name: /* Your target name here */, dependencies: ["Conbini"], swiftSettings: [.define("CONBINI_FOR_TESTING")])
]
```

</p></details>

<details><summary>Import <code>Conbini</code> in the file that needs it.</summary><p>
Expand All @@ -40,6 +48,11 @@ let package = Package(
import Conbini
```

The testing conveniences depend on [XCTest](https://developer.apple.com/documentation/xctest), which is not available on regular execution. That is why Conbini is offered in two flavors:

- `import Conbini` includes all code excepts the testing conveniences.
- `import ConbiniForTesting` includes the testing functionality only.

</p></details>
</ul>

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#if !os(watchOS) && canImport(XCTest)
#if !os(watchOS)
import XCTest
import Combine

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#if !os(watchOS) && canImport(XCTest)
#if !os(watchOS)
import XCTest
import Combine
import Foundation
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#if !os(watchOS)
import XCTest
import Conbini
import Combine
Expand Down Expand Up @@ -54,4 +53,3 @@ extension AssignOpTests {
XCTAssert(objC.value == data.last!)
}
}
#endif
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#if !os(watchOS)
import XCTest
import Conbini
import Combine
Expand Down Expand Up @@ -101,4 +100,3 @@ extension DelayedRetryOpTests {
cancellable.cancel()
}
}
#endif
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#if !os(watchOS)
import XCTest
import Conbini
import Combine
Expand Down Expand Up @@ -132,4 +131,3 @@ extension HandleEndOpTests {
cancellable.cancel()
}
}
#endif
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#if !os(watchOS)
import XCTest
import Conbini
import Combine
Expand Down Expand Up @@ -74,4 +73,3 @@ extension ResultOpTests {
self.wait(for: [expA], timeout: 0.2)
}
}
#endif
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#if !os(watchOS)
import XCTest
import Conbini
import Combine
Expand Down Expand Up @@ -55,4 +54,3 @@ extension ThenOpTests {
cancellable.cancel()
}
}
#endif
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#if !os(watchOS)
import XCTest
import Conbini
import Combine
Expand Down Expand Up @@ -90,4 +89,3 @@ extension DeferredCompleteTests {
cancellable.cancel()
}
}
#endif
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#if !os(watchOS)
import XCTest
import Conbini
import Combine
Expand Down Expand Up @@ -80,4 +79,3 @@ extension DeferredFutureTests {
cancellable.cancel()
}
}
#endif
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#if !os(watchOS)
import XCTest
import Conbini
import Combine
Expand Down Expand Up @@ -87,4 +86,3 @@ extension DeferredPassthroughTests {
XCTAssertEqual(.init(values.prefix(upTo: 2)), receivedValues)
}
}
#endif
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#if !os(watchOS)
import XCTest
import Conbini
import Combine
Expand Down Expand Up @@ -53,4 +52,3 @@ extension DeferredResultTests {
self.wait(for: [exp], timeout: 0.2)
}
}
#endif
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#if !os(watchOS)
import XCTest
import Conbini
import Combine
Expand Down Expand Up @@ -83,4 +82,3 @@ extension DeferredTryCompleteTests {
self.wait(for: [exp], timeout: 0.2)
}
}
#endif
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#if !os(watchOS)
import XCTest
import Conbini
import Combine
Expand Down Expand Up @@ -51,4 +50,3 @@ extension DeferredTryValueTests {
self.wait(for: [exp], timeout: 0.2)
}
}
#endif
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#if !os(watchOS)
import XCTest
import Conbini
import Combine
Expand Down Expand Up @@ -37,4 +36,3 @@ extension DeferredValueTests {
self.wait(for: [exp], timeout: 0.2)
}
}
#endif
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#if !os(watchOS)
import XCTest
import Conbini
import Combine
Expand Down Expand Up @@ -86,4 +85,3 @@ extension FixedSinkTests {
subscriber.cancel()
}
}
#endif
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#if !os(watchOS)
import XCTest
import Conbini
import Combine
Expand Down Expand Up @@ -65,4 +64,3 @@ extension GraduatedSinkTests {
subscriber.cancel()
}
}
#endif
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#if !os(watchOS)
import XCTest
import Conbini
import Combine
Expand Down Expand Up @@ -70,4 +69,3 @@ extension BufferTests {
XCTAssertEqual(input.map { $0 * 4 }, output)
}
}
#endif
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#if !os(watchOS)
import XCTest
import Conbini
import ConbiniForTesting
import Combine

/// Tests the correct behavior of the *expectation* conveniences.
Expand Down Expand Up @@ -82,4 +82,3 @@ extension ExpectationsTests {
XCTAssertEqual(.init(values[0..<2]), subjectEmitted)
}
}
#endif

0 comments on commit 4fb8c17

Please sign in to comment.