Skip to content

Commit

Permalink
Merge pull request Quick#897 from Quick/swiftlint-address-reduce_bool…
Browse files Browse the repository at this point in the history
…ean-warnings

[SwiftLint] Address reduce_boolean warnings
  • Loading branch information
ikesyo authored Jun 8, 2019
2 parents 2c2a6e6 + a89df5a commit d3f39da
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Sources/Quick/World.swift
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ final internal class World: _WorldBase {
let spec = rootExampleGroup(forSpecClass: specClass).examples.filter { included.contains($0) }
// 3. Remove all excluded examples.
return spec.filter { example in
!self.configuration.exclusionFilters.reduce(false) { $0 || $1(example) }
!self.configuration.exclusionFilters.contains { $0(example) }
}
}

Expand Down Expand Up @@ -223,7 +223,7 @@ final internal class World: _WorldBase {
private var includedExamples: [Example] {
let all = allExamples
let included = all.filter { example in
return self.configuration.inclusionFilters.reduce(false) { $0 || $1(example) }
return self.configuration.inclusionFilters.contains { $0(example) }
}

if included.isEmpty && configuration.runAllWhenEverythingFiltered {
Expand Down

0 comments on commit d3f39da

Please sign in to comment.