Skip to content
This repository was archived by the owner on Jun 30, 2021. It is now read-only.

Commit adbafe3

Browse files
committed
TravisCI switch to the new feature: Stages
1 parent 6965f7c commit adbafe3

File tree

6 files changed

+41
-53
lines changed

6 files changed

+41
-53
lines changed

.travis.yml

Lines changed: 38 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,14 @@
44
# Note: `language: generic` was failing in OSX so in that case you can use language: c
55
language: generic
66

7+
sudo: required
8+
9+
os: linux
10+
dist: trusty
11+
12+
services:
13+
- docker
14+
715
# Omit running tests on temporal branches,
816
# i.e. branches with names that start with "tmp"
917
branches:
@@ -14,40 +22,35 @@ env:
1422
global:
1523
- TEST_SLEEPS="0.7"
1624
- ADDED_TEST_SLEEP="6.5"
25+
- DOCKER_VERSION="stable"
26+
- DOCKER_PUSH=true
27+
- DOCKER_PUSH_LATEST=true
1728

18-
matrix:
29+
jobs:
1930
include:
20-
# Linux with docker:stable compose:stable
21-
# Use DOCKER_PUSH_LATEST=false to debug
22-
- os: linux
23-
language: generic
24-
sudo: required
25-
dist: trusty
26-
services:
27-
- docker
28-
env:
29-
- DOCKER_VERSION="stable"
30-
DOCKER_PUSH=true
31-
DOCKER_PUSH_LATEST=true
32-
33-
before_install:
34-
- travis_retry ./test/before_install_setup
35-
- travis_retry ./test/before_install_build
36-
37-
install:
38-
- ./test/install
39-
40-
script:
41-
- ./test/script_start
42-
- travis_retry ./test/script_scenario_basic
43-
- travis_retry ./test/script_scenario_restart
44-
- travis_retry ./test/script_scenario_node_dies
45-
- travis_retry ./test/script_scenario_make
46-
- travis_retry ./test/script_scenario_compose_N_N
47-
48-
# cleanup though doesn't seem to be necessary in Travis infra
49-
after_script:
50-
- ./test/after_script
51-
52-
after_success:
53-
- ./test/script_end
31+
- stage: Integration and Unit Tests
32+
env: test=scenario_basic__restart
33+
script:
34+
- travis_retry ./test/before_install_build
35+
- travis_retry ./test/script_scenario_basic
36+
- travis_retry ./test/script_scenario_restart
37+
38+
- env: test=scenario_node_dies
39+
script:
40+
- travis_retry ./test/before_install_build
41+
- travis_retry ./test/script_scenario_node_dies
42+
43+
- env: test=scenario_make
44+
script:
45+
- travis_retry ./test/before_install_build
46+
- travis_retry ./test/script_scenario_make
47+
48+
- env: test=scenario_compose_N_N
49+
script:
50+
- travis_retry ./test/before_install_build
51+
- travis_retry ./test/script_scenario_compose_N_N
52+
53+
- stage: Push Image (only with a tag)
54+
script:
55+
- travis_retry ./test/before_install_build
56+
- ./test/script_push

CONTRIBUTING.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,9 @@
44
For pull requests or local commits:
55

66
git checkout -b tmp-`cat VERSION`
7-
time (./test/bef && ./test/install && ./test/script_start && ./test/script_end)
7+
time (./test/bef && ./test/script_start && ./test/script_archive)
88
open ./images/grid3_console.png && open ./videos/mobile_emulation/*.mp4
9-
docker exec grid versions && ./test/after_script && travis lint
10-
git checkout ./images/grid3_console.png scm-source.json
9+
docker exec grid versions && ./test/after_script && git checkout scm-source.json
1110
#git add ... git commit ... git push ... open pull request
1211

1312
For repository owners only:

images/grid3_console.png

-98 Bytes
Loading

test/install

Lines changed: 0 additions & 6 deletions
This file was deleted.

test/script_end

Lines changed: 0 additions & 8 deletions
This file was deleted.

test/script_push

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ update_changelog() {
9797
# + Image ID: TBD_IMAGE_ID
9898
# + ...
9999
# Test locally with:
100-
# ./test/before_install_build && ./test/install
100+
# ./test/before_install_build
101101
# TRAVIS_TAG=$(git rev-parse --abbrev-ref HEAD | grep -Po '(?<=tmp\-)([a-z0-9\.]+)')
102102
# docker tag selenium:latest elgalu/selenium:${TRAVIS_TAG}
103103
# Cleanup:

0 commit comments

Comments
 (0)