Skip to content

Commit

Permalink
[Testing] Travis testing devices updates. (material-components#1595)
Browse files Browse the repository at this point in the history
* [Testing] Updating test_all for multiple devices.

* [Testing] Setting Travis device matrix to use a 32-bit device.

* [Testing] Comments in Travis file.

* [Testing] Bumping Travis testing 'latest' version to 10.3.

* [Testing] Correcting Travis device target.
  • Loading branch information
willlarche authored Jul 5, 2017
1 parent eec61cf commit cf6da2e
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
6 changes: 4 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,10 @@ env:
- LC_CTYPE=en_US.UTF-8
- LANG=en_US.UTF-8
matrix:
- DESTINATION="platform=iOS Simulator,name=iPhone 7,OS=10.2" SDK="iphonesimulator10.2"
- DESTINATION="platform=iOS Simulator,name=iPhone 5s,OS=8.1" SDK="iphonesimulator8.1"
- DESTINATION="platform=iOS Simulator,name=iPhone 7,OS=10.3.1" SDK="iphonesimulator10.3.1"
# The iPhone 5 was chosen because it is a 32-bit device.
# 8.1 was chosen because it is the earliest iOS offered here.
- DESTINATION="platform=iOS Simulator,name=iPhone 5,OS=8.1" SDK="iphonesimulator8.1"

before_install:
- gem install xcpretty --no-rdoc --no-ri --no-document --quiet
Expand Down
10 changes: 7 additions & 3 deletions scripts/test_all
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,13 @@

readonly SCRIPTS_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
readonly ROOT_DIR="$(dirname $SCRIPTS_DIR)"
readonly DESTINATION="platform=iOS Simulator,name=iPhone 7,OS=latest"
readonly COVERAGE_OPTIONS="GCC_INSTRUMENT_PROGRAM_FLOW_ARCS=YES GCC_GENERATE_TEST_COVERAGE_FILES=YES -enableCodeCoverage YES"

# When run on Travis CI, this variable should be passed in
if [[ ! $DESTINATION ]]; then
DESTINATION="platform=iOS Simulator,name=iPhone 7,OS=latest"
fi

# Given a path to an Xcode log file in $1, print a guess at what caused the
# failure.
function guess_failure() {
Expand All @@ -36,7 +40,7 @@ else
fi

all_tests_ok=1
for workspace_scheme in $WORKSPACE_SCHEMES; do
for workspace_scheme in $WORKSPACE_SCHEMES; do
workspace=$(echo $workspace_scheme | cut -d: -f1)
scheme=$(echo $workspace_scheme | cut -d: -f2)

Expand All @@ -60,7 +64,7 @@ for workspace_scheme in $WORKSPACE_SCHEMES; do
fi
done

# If any test failed, exit with a failure exit status so continuous integration
# If any test failed, exit with a failure exit status so continuous integration
# tools can react appropriately.
if [ "$all_tests_ok" -eq 1 ]; then
exit 0
Expand Down

0 comments on commit cf6da2e

Please sign in to comment.