Swiftmazing
A iOS application with layout based on App Store that can check the most starred and last updated Swift repository. It was developed in a modular way, with their respective tests using Quick, Nimble, Snapshots and/or KIF, the using the modern collection view and integrated with fastlane and slather generating test coverage.
Features
- Modularization
- CLEAN Swift Architecture (VIP)
- Modern Collection View
- Mock Mode
- Pull-to-Refresh
- Infinity Scroll using PrefetchItems
- View Code (UIKit)
- Preview using UIViewRepresentable
- Dark Mode
- Internationalization (English and PT-Br)
- Unit tests
- Snapshots Tests
- Functional Tests
- Travis CI integration
- Codecov integration
- Fastlane integration
- Slather integration
Prerequisites
Installing
First of all download and install Xcode, Cocoapods and xcodegen, then clone the repository
https://github.com/HelioMesquita/Swiftmazing.git
Go to cloned directory and execute
xcodegen generate
Open the directory project and double tap on Swiftmazing.xcworkspace
Running the tests
For each scheme in project run some tests targets
- The visual scheme runs the snapshots tests for all views and view controllers
- The Infrastructure scheme runs the unit tests using Quick and Nimble for all network tests
- The Swiftmazing scheme runs the unit tests using Quick and Nimble for all bussiness and presentation rules
- The SwiftmazingMock scheme runs the functional tests using KIF in a mocked application
- The SwiftmazingTests scheme runs all tests
The all tests can be run also using Fastlane just execute
bundle install
bundle exec fastlane tests
When running the tests using this command automaticaly runs Slather that generates a test relatory of code coverage in xml. The relatory can be found at
fastlane/slather
If you want to see relatory in html, modify the .slather.yml
changing key coverage_service
to html