Skip to content

Commit

Permalink
chore: Improve CI (#135)
Browse files Browse the repository at this point in the history
* chore: Fix lint issues

* chore: Bump fastlane version

* chore: Update Gemfile.lock

* chore: Update deployment script

* chore: fix lint issues

* chore: make release commit name semantic

* chore: Fix integration tests
  • Loading branch information
VladislavFitz authored Oct 16, 2020
1 parent 6261916 commit bd3b1e4
Show file tree
Hide file tree
Showing 68 changed files with 369 additions and 382 deletions.
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@ source "https://rubygems.org"
git_source(:github) {|repo_name| "https://github.com/#{repo_name}" }

gem 'cocoapods', '~> 1.9'
gem 'fastlane', '~> 2.151'
gem 'fastlane', '~> 2.163'
gem 'xcov'
54 changes: 27 additions & 27 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -14,22 +14,22 @@ GEM
json (>= 1.5.1)
atomos (0.1.3)
aws-eventstream (1.1.0)
aws-partitions (1.341.0)
aws-sdk-core (3.103.0)
aws-partitions (1.382.0)
aws-sdk-core (3.109.1)
aws-eventstream (~> 1, >= 1.0.2)
aws-partitions (~> 1, >= 1.239.0)
aws-sigv4 (~> 1.1)
jmespath (~> 1.0)
aws-sdk-kms (1.36.0)
aws-sdk-core (~> 3, >= 3.99.0)
aws-sdk-kms (1.39.0)
aws-sdk-core (~> 3, >= 3.109.0)
aws-sigv4 (~> 1.1)
aws-sdk-s3 (1.74.0)
aws-sdk-core (~> 3, >= 3.102.1)
aws-sdk-s3 (1.83.0)
aws-sdk-core (~> 3, >= 3.109.0)
aws-sdk-kms (~> 1)
aws-sigv4 (~> 1.1)
aws-sigv4 (1.2.1)
aws-sigv4 (1.2.2)
aws-eventstream (~> 1, >= 1.0.2)
babosa (1.0.3)
babosa (1.0.4)
claide (1.0.3)
cocoapods (1.9.3)
activesupport (>= 4.0.2, < 5)
Expand Down Expand Up @@ -79,21 +79,21 @@ GEM
rake (~> 13.0)
domain_name (0.5.20190701)
unf (>= 0.0.5, < 1.0.0)
dotenv (2.7.5)
dotenv (2.7.6)
emoji_regex (3.0.0)
escape (0.0.4)
ethon (0.12.0)
ffi (>= 1.3.0)
excon (0.75.0)
excon (0.76.0)
faraday (1.0.1)
multipart-post (>= 1.2, < 3)
faraday-cookie_jar (0.0.6)
faraday (>= 0.7.4)
faraday-cookie_jar (0.0.7)
faraday (>= 0.8.0)
http-cookie (~> 1.0.0)
faraday_middleware (1.0.0)
faraday (~> 1.0)
fastimage (2.1.7)
fastlane (2.151.2)
fastimage (2.2.0)
fastlane (2.163.0)
CFPropertyList (>= 2.3, < 4.0.0)
addressable (>= 2.3, < 3.0.0)
aws-sdk-s3 (~> 1.0)
Expand All @@ -104,9 +104,9 @@ GEM
dotenv (>= 2.1.1, < 3.0.0)
emoji_regex (>= 0.1, < 4.0)
excon (>= 0.71.0, < 1.0.0)
faraday (>= 0.17, < 2.0)
faraday (~> 1.0)
faraday-cookie_jar (~> 0.0.6)
faraday_middleware (>= 0.13.1, < 2.0)
faraday_middleware (~> 1.0)
fastimage (>= 2.1.0, < 3.0.0)
gh_inspector (>= 1.1.2, < 2.0.0)
google-api-client (>= 0.37.0, < 0.39.0)
Expand Down Expand Up @@ -144,17 +144,17 @@ GEM
google-cloud-core (1.5.0)
google-cloud-env (~> 1.0)
google-cloud-errors (~> 1.0)
google-cloud-env (1.3.2)
google-cloud-env (1.4.0)
faraday (>= 0.17.3, < 2.0)
google-cloud-errors (1.0.1)
google-cloud-storage (1.26.2)
google-cloud-storage (1.29.1)
addressable (~> 2.5)
digest-crc (~> 0.4)
google-api-client (~> 0.33)
google-cloud-core (~> 1.2)
googleauth (~> 0.9)
mini_mime (~> 1.0)
googleauth (0.13.0)
googleauth (0.14.0)
faraday (>= 0.17.3, < 2.0)
jwt (>= 1.4, < 3.0)
memoist (~> 0.16)
Expand All @@ -169,21 +169,21 @@ GEM
concurrent-ruby (~> 1.0)
jmespath (1.4.0)
json (2.3.1)
jwt (2.2.1)
jwt (2.2.2)
memoist (0.16.2)
mini_magick (4.10.1)
mini_mime (1.0.2)
minitest (5.14.1)
molinillo (0.6.6)
multi_json (1.15.0)
multipart-post (2.0.0)
nanaimo (0.2.6)
nanaimo (0.3.0)
nap (1.1.0)
naturally (2.2.0)
netrc (0.11.0)
os (1.1.0)
os (1.1.1)
plist (3.5.0)
public_suffix (4.0.5)
public_suffix (4.0.6)
rake (13.0.1)
representable (3.0.4)
declarative (< 0.1.0)
Expand All @@ -208,7 +208,7 @@ GEM
unicode-display_width (~> 1.1, >= 1.1.1)
thread_safe (0.3.6)
tty-cursor (0.7.1)
tty-screen (0.8.0)
tty-screen (0.8.1)
tty-spinner (0.9.3)
tty-cursor (~> 0.7)
typhoeus (1.4.0)
Expand All @@ -221,12 +221,12 @@ GEM
unf_ext (0.0.7.7)
unicode-display_width (1.7.0)
word_wrap (1.0.0)
xcodeproj (1.17.0)
xcodeproj (1.19.0)
CFPropertyList (>= 2.3.3, < 4.0)
atomos (~> 0.1.3)
claide (>= 1.0.2, < 2.0)
colored2 (~> 3.1)
nanaimo (~> 0.2.6)
nanaimo (~> 0.3.0)
xcov (1.7.3)
fastlane (>= 2.141.0, < 3.0.0)
multipart-post
Expand All @@ -245,7 +245,7 @@ PLATFORMS

DEPENDENCIES
cocoapods (~> 1.9)
fastlane (~> 2.151)
fastlane (~> 2.163)
xcov

BUNDLED WITH
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import InstantSearchCore
import UIKit

public extension MultiIndexSearchConnector {

@available(iOS 13.0, *)
init<HC: MultiIndexHitsController>(searcher: MultiIndexSearcher,
indexModules: [MultiIndexHitsConnector.IndexModule],
Expand All @@ -26,7 +26,7 @@ public extension MultiIndexSearchConnector {
queryInputInteractor: queryInputInteractor,
queryInputController: textFieldController)
}

@available(iOS 13.0, *)
init<HC: MultiIndexHitsController>(appID: ApplicationID,
apiKey: APIKey,
Expand All @@ -41,7 +41,7 @@ public extension MultiIndexSearchConnector {
searchController: searchController,
hitsController: hitsController)
}

}

#endif
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import InstantSearchCore
import UIKit

public extension SingleIndexSearchConnector {

@available(iOS 13.0, *)
init<HC: HitsController>(searcher: SingleIndexSearcher,
searchController: UISearchController,
Expand All @@ -28,7 +28,7 @@ public extension SingleIndexSearchConnector {
hitsController: hitsController,
filterState: filterState)
}

@available(iOS 13.0, *)
init<HC: HitsController>(appID: ApplicationID,
apiKey: APIKey,
Expand All @@ -46,6 +46,6 @@ public extension SingleIndexSearchConnector {
hitsController: hitsController,
filterState: filterState)
}

}
#endif
Original file line number Diff line number Diff line change
Expand Up @@ -13,32 +13,32 @@ import InstantSearchCore
import UIKit

open class HitsCollectionViewController<CellConfigurator: CollectionViewCellConfigurable>: UICollectionViewController, UICollectionViewDelegateFlowLayout, HitsController {

public var hitsSource: HitsInteractor<CellConfigurator.Model>?

open override func viewDidLoad() {
super.viewDidLoad()
collectionView.register(CellConfigurator.Cell.self, forCellWithReuseIdentifier: CellConfigurator.cellIdentifier)
}

open override func collectionView(_ collectionView: UICollectionView, numberOfItemsInSection section: Int) -> Int {
return hitsSource?.numberOfHits() ?? 0
}

open override func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -> UICollectionViewCell {
return collectionView.dequeueReusableCell(withReuseIdentifier: CellConfigurator.cellIdentifier, for: indexPath)
}

open override func collectionView(_ collectionView: UICollectionView, willDisplay cell: UICollectionViewCell, forItemAt indexPath: IndexPath) {
guard let cell = cell as? CellConfigurator.Cell else { return }
guard let model = hitsSource?.hit(atIndex: indexPath.row) else { return }
CellConfigurator(model: model, indexPath: indexPath).configure(cell)
}

public func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, sizeForItemAt indexPath: IndexPath) -> CGSize {
guard let model = hitsSource?.hit(atIndex: indexPath.row) else { return .zero }
return CellConfigurator(model: model, indexPath: indexPath).cellSize
}

}
#endif
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ import InstantSearchCore
import UIKit

open class HitsTableViewController<CellConfigurator: TableViewCellConfigurable>: UITableViewController, HitsController {

public var hitsSource: HitsInteractor<CellConfigurator.Model>?

open override func viewDidLoad() {
super.viewDidLoad()
tableView.register(CellConfigurator.Cell.self, forCellReuseIdentifier: CellConfigurator.cellIdentifier)
Expand All @@ -24,21 +24,21 @@ open class HitsTableViewController<CellConfigurator: TableViewCellConfigurable>:
open override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
return hitsSource?.numberOfHits() ?? 0
}

open override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
return tableView.dequeueReusableCell(withIdentifier: CellConfigurator.cellIdentifier, for: indexPath)
}

open override func tableView(_ tableView: UITableView, willDisplay cell: UITableViewCell, forRowAt indexPath: IndexPath) {
guard let cell = cell as? CellConfigurator.Cell else { return }
guard let model = hitsSource?.hit(atIndex: indexPath.row) else { return }
CellConfigurator(model: model, indexPath: indexPath).configure(cell)
}

open override func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
guard let model = hitsSource?.hit(atIndex: indexPath.row) else { return 0 }
return CellConfigurator(model: model, indexPath: indexPath).cellHeight
}

}
#endif
Original file line number Diff line number Diff line change
Expand Up @@ -21,19 +21,19 @@ Connector encapsulating basic search experience within multiple indices
Most of the components associated by this connector are created and connected automatically, it's only required to provide a proper `Controller` implementations.
*/
public struct MultiIndexSearchConnector: Connection {

/// Connector establishing the linkage between searcher, hits interactor and optionally filter state
public let hitsConnector: MultiIndexHitsConnector

/// Connection between hits interactor of hits connector and provided hits controller
public let hitsControllerConnection: Connection

/// Connector establishing the linkage between searcher and query input interactor
public let queryInputConnector: QueryInputConnector<MultiIndexSearcher>

/// Connection between query input interactor of query input connector and provided query input controller
public let queryInputControllerConnection: Connection

/**
- Parameters:
- searcher: External multi index sercher
Expand All @@ -55,7 +55,7 @@ public struct MultiIndexSearchConnector: Connection {
queryInputControllerConnection = queryInputInteractor.connectController(queryInputController)
searcher.search()
}

/**
- Parameters:
- appID: Application ID
Expand All @@ -80,20 +80,20 @@ public struct MultiIndexSearchConnector: Connection {
queryInputInteractor: queryInputInteractor,
queryInputController: queryInputController)
}

public func connect() {
disconnect()
hitsConnector.connect()
hitsControllerConnection.connect()
queryInputConnector.connect()
queryInputControllerConnection.connect()
}

public func disconnect() {
hitsConnector.disconnect()
hitsControllerConnection.disconnect()
queryInputConnector.disconnect()
queryInputControllerConnection.disconnect()
}

}
Loading

0 comments on commit bd3b1e4

Please sign in to comment.