Skip to content

Commit

Permalink
update RxSwfit to 6.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
raphkoebraam committed Jan 3, 2021
1 parent e50d2b5 commit 408d079
Show file tree
Hide file tree
Showing 7 changed files with 29 additions and 29 deletions.
2 changes: 1 addition & 1 deletion Cartfile
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
github "Alamofire/Alamofire" ~> 5.0
github "ReactiveCocoa/ReactiveSwift" ~> 6.0
github "ReactiveX/RxSwift" ~> 5.0
github "ReactiveX/RxSwift" ~> 6.0
12 changes: 6 additions & 6 deletions Cartfile.resolved
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
github "Alamofire/Alamofire" "5.0.0"
github "AliSoftware/OHHTTPStubs" "9.0.0"
github "Quick/Nimble" "v8.0.5"
github "Quick/Quick" "v2.2.0"
github "ReactiveCocoa/ReactiveSwift" "6.2.0"
github "ReactiveX/RxSwift" "5.0.1"
github "Alamofire/Alamofire" "5.4.1"
github "AliSoftware/OHHTTPStubs" "9.1.0"
github "Quick/Nimble" "v8.1.2"
github "Quick/Quick" "v2.2.1"
github "ReactiveCocoa/ReactiveSwift" "6.5.0"
github "ReactiveX/RxSwift" "6.0.0"
2 changes: 1 addition & 1 deletion Moya.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,6 @@ Pod::Spec.new do |s|
s.subspec "RxSwift" do |ss|
ss.source_files = "Sources/RxMoya/"
ss.dependency "Moya/Core"
ss.dependency "RxSwift", "~> 5.0"
ss.dependency "RxSwift", "~> 6.0"
end
end
2 changes: 1 addition & 1 deletion Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ let package = Package(
dependencies: [
.package(url: "https://github.com/Alamofire/Alamofire.git", .upToNextMajor(from: "5.0.0")),
.package(url: "https://github.com/Moya/ReactiveSwift.git", .upToNextMajor(from: "6.1.0")),
.package(url: "https://github.com/ReactiveX/RxSwift.git", .upToNextMajor(from: "5.0.0")),
.package(url: "https://github.com/ReactiveX/RxSwift.git", .upToNextMajor(from: "6.0.0")),
.package(url: "https://github.com/Quick/Quick.git", .upToNextMajor(from: "2.0.0")), // dev
.package(url: "https://github.com/Quick/Nimble.git", .upToNextMajor(from: "8.0.0")), // dev
.package(url: "https://github.com/AliSoftware/OHHTTPStubs.git", .upToNextMajor(from: "9.0.0")) // dev
Expand Down
2 changes: 1 addition & 1 deletion Sources/RxMoya/MoyaProvider+Rx.swift
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public extension Reactive where Base: MoyaProviderType {
case let .success(response):
single(.success(response))
case let .failure(error):
single(.error(error))
single(.failure(error))
}
}

Expand Down
16 changes: 8 additions & 8 deletions Tests/MoyaTests/MoyaProvider+RxSpec.swift
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ final class MoyaProviderRxSpec: QuickSpec {

_ = provider.rx.request(.zen).subscribe { event in
switch event {
case .success: called = true
case .error(let error): fail("errored: \(error)")
case .success: called = true
case .failure(let error): fail("errored: \(error)")
}
}

Expand All @@ -39,7 +39,7 @@ final class MoyaProviderRxSpec: QuickSpec {
_ = provider.rx.request(target).subscribe { event in
switch event {
case .success(let response): responseData = response.data
case .error(let error): fail("errored: \(error)")
case .failure(let error): fail("errored: \(error)")
}
}

Expand Down Expand Up @@ -70,8 +70,8 @@ final class MoyaProviderRxSpec: QuickSpec {

_ = provider.rx.request(.zen).subscribe { event in
switch event {
case .success: fail("should have errored")
case .error(let error): receivedError = error as? MoyaError
case .success: fail("should have errored")
case .failure(let error): receivedError = error as? MoyaError
}
}

Expand All @@ -90,7 +90,7 @@ final class MoyaProviderRxSpec: QuickSpec {
_ = provider.rx.request(target).subscribe { event in
switch event {
case .success: fail("we should have errored")
case .error: errored = true
case .failure: errored = true
}
}

Expand Down Expand Up @@ -123,7 +123,7 @@ final class MoyaProviderRxSpec: QuickSpec {
receivedResponse = response
expect(provider.inflightRequests.count).to(equal(1))

case .error(let error):
case .failure(let error):
fail("errored: \(error)")
}
}
Expand All @@ -135,7 +135,7 @@ final class MoyaProviderRxSpec: QuickSpec {
expect(receivedResponse).to(beIdenticalToResponse(response))
expect(provider.inflightRequests.count).to(equal(1))

case .error(let error):
case .failure(let error):
fail("errored: \(error)")
}
}
Expand Down
22 changes: 11 additions & 11 deletions Tests/MoyaTests/Single+MoyaSpec.swift
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ final class SingleMoyaSpec: QuickSpec {
switch event {
case .success(let object):
fail("called on non-correct status code: \(object)")
case .error:
case .failure:
errored = true
}
}
Expand All @@ -33,7 +33,7 @@ final class SingleMoyaSpec: QuickSpec {
switch event {
case .success(let object):
fail("called on non-correct status code: \(object)")
case .error:
case .failure:
errored = true
}
}
Expand All @@ -50,7 +50,7 @@ final class SingleMoyaSpec: QuickSpec {
switch event {
case .success(let object):
fail("called on non-correct status code: \(object)")
case .error:
case .failure:
errored = true
}
}
Expand All @@ -67,7 +67,7 @@ final class SingleMoyaSpec: QuickSpec {
switch event {
case .success(let object):
fail("called on non-correct status code: \(object)")
case .error:
case .failure:
errored = true
}
}
Expand All @@ -84,7 +84,7 @@ final class SingleMoyaSpec: QuickSpec {
switch event {
case .success(let object):
fail("called on non-success status code: \(object)")
case .error:
case .failure:
errored = true
}
}
Expand Down Expand Up @@ -113,7 +113,7 @@ final class SingleMoyaSpec: QuickSpec {
switch event {
case .success(let object):
fail("called on non-success status code: \(object)")
case .error:
case .failure:
errored = true
}
}
Expand Down Expand Up @@ -166,7 +166,7 @@ final class SingleMoyaSpec: QuickSpec {
switch event {
case .success(let object):
fail("called on non-success status code: \(object)")
case .error:
case .failure:
errored = true
}
}
Expand Down Expand Up @@ -201,7 +201,7 @@ final class SingleMoyaSpec: QuickSpec {
switch event {
case .success:
fail("next called for invalid data")
case .error(let error):
case .failure(let error):
receivedError = error as? MoyaError
}
}
Expand Down Expand Up @@ -245,7 +245,7 @@ final class SingleMoyaSpec: QuickSpec {
switch event {
case .success:
fail("next called for invalid data")
case .error(let error):
case .failure(let error):
receivedError = error as? MoyaError
}
}
Expand Down Expand Up @@ -303,7 +303,7 @@ final class SingleMoyaSpec: QuickSpec {
switch event {
case .success:
fail("next called for invalid data")
case .error(let error):
case .failure(let error):
receivedError = error as? MoyaError
}
}
Expand Down Expand Up @@ -570,7 +570,7 @@ final class SingleMoyaSpec: QuickSpec {
switch event {
case .success:
fail("success called for invalid data")
case .error(let error):
case .failure(let error):
receivedError = error
}
}
Expand Down

0 comments on commit 408d079

Please sign in to comment.