Skip to content

Latest commit

 

History

History
61 lines (49 loc) · 2.08 KB

CONTRIBUTING.md

File metadata and controls

61 lines (49 loc) · 2.08 KB

Contributing to Pact Consumer Swift project

Prepare your development environment

The Pact Consumer Swift library is using Carthage and Swift Package Manager to manage library dependencies. You should install Carthage using Homebrew, then download and build the dependencies using carthage bootstrap (Carthage).

Required build dependencies can be installed by running:

./scripts/install_deps.sh

Running tests with default destination

./scripts/build.sh

defaults to iOS 11 on iPhone 8

Running specific platform tests

iOS 10.3 on iPhone 7:

xcodebuild -project PactConsumerSwift.xcodeproj -scheme "PactConsumerSwift iOS" -destination "OS=10.3,name=iPhone 7" -configuration Debug ONLY_ACTIVE_ARCH=NO ENABLE_TESTABILITY=YES test | xcbeautify;

for macOS:

xcodebuild -project PactConsumerSwift.xcodeproj -scheme "PactConsumerSwift macOS" -destination "arch=x86_64" -configuration Debug ONLY_ACTIVE_ARCH=NO ENABLE_TESTABILITY=YES test | xcbeautify;

for tvOS:

xcodebuild -project PactConsumerSwift.xcodeproj -scheme PactConsumerSwift tvOS -destination OS=11.0,name=Apple TV 4K (at 1080p) -configuration Debug ONLY_ACTIVE_ARCH=NO ENABLE_TESTABILITY=YES test | xcbeautify;

Test CocoaPods

pod spec lint PactConsumerSwift.podspec --allow-warnings

Getting set up to work with CocoaPods.

Test Carthage

carthage build --no-skip-current --platform iOS,macOS,tvOS

Test Swift Package Manager

./scripts/start_server.sh &&
swift build -c debug | release &&
swift test &&
./scripts/stop_server.sh

For more information, see the .travis.yml configuration.

TravisCI

Builds on Travis CI with pipeline configuration in .travis.yml.

Release

release.sh script helps with updating the Changelog, tagging the commit with a release version, and publish to Cocoapods.

./scripts/release.sh 0.7.0 "Bugfix Release"