Skip to content

Commit affa038

Browse files
authored
Merge pull request #458 from nickmshelley/travis-jobs
Closes #457: Split up tests into more Travis jobs.
2 parents 0ff5262 + 38dd7e5 commit affa038

File tree

3 files changed

+21
-5
lines changed

3 files changed

+21
-5
lines changed

.travis.yml

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
11
language: objective-c
2-
env:
3-
- BUILD_SCHEME="SQLite iOS"
4-
- BUILD_SCHEME="SQLite Mac"
2+
matrix:
3+
include:
4+
- env: BUILD_SCHEME="SQLite iOS"
5+
- env: BUILD_SCHEME="SQLite Mac"
6+
- env: VALIDATOR_SUBSPEC="none"
7+
- env: VALIDATOR_SUBSPEC="standard"
8+
- env: VALIDATOR_SUBSPEC="standalone"
59
before_install:
610
- gem install xcpretty --no-document
711
script:
8-
- make test
9-
- cd CocoaPodsTests && make test
12+
- ./run-tests.sh
1013
osx_image: xcode7.3

CocoaPodsTests/integration_test.rb

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,19 @@ def test_validate_project
1313

1414
def validator
1515
@validator ||= TestRunningValidator.new(podspec, []).tap do |validator|
16+
subspec = ENV["VALIDATOR_SUBSPEC"]
1617
validator.test_files = Dir["#{project_test_dir}/*.swift"]
1718
validator.config.verbose = true
1819
validator.no_clean = true
1920
validator.use_frameworks = true
2021
validator.fail_fast = true
2122
validator.local = true
2223
validator.allow_warnings = true
24+
if subspec == "none"
25+
validator.no_subspecs = true
26+
else
27+
validator.only_subspec = subspec
28+
end
2329
end
2430
end
2531

run-tests.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
#!/bin/bash
2+
set -ev
3+
if [ -n "$BUILD_SCHEME" ]; then
4+
make test
5+
elif [ -n "$VALIDATOR_SUBSPEC" ]; then
6+
cd CocoaPodsTests && make test
7+
fi

0 commit comments

Comments
 (0)