-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Prune Comment System Tests for Faster CI (#9752)
* prune comment system tests #9069 * break comment system tests out to separate workflow #9069 * increase after_n_builds by 1 #9069 * change rails test command #9069 * removed extra "end" Co-authored-by: jywarren <[email protected]>
- Loading branch information
Showing
3 changed files
with
160 additions
and
113 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -141,6 +141,53 @@ jobs: | |
name: system-test-screenshots | ||
path: tmp/screenshots/* | ||
|
||
comment-system-tests: | ||
runs-on: ubuntu-latest | ||
services: | ||
redis: | ||
image: redis | ||
# Set health checks to wait until redis has started | ||
options: >- | ||
--health-cmd "redis-cli ping" | ||
--health-interval 10s | ||
--health-timeout 5s | ||
--health-retries 5 | ||
ports: | ||
# Maps port 6379 on service container to the host | ||
- 6379:6379 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: ruby/setup-ruby@v1 | ||
with: | ||
ruby-version: 2.6.6 # Not needed with a .ruby-version file | ||
bundler-cache: true # runs 'bundle install' and caches installed gems automatically (not working?) | ||
- uses: nanasess/[email protected] | ||
- uses: ./.github/actions/setup-test-environment | ||
- name: Install JavaScript dependencies with Yarn | ||
run: yarn check || yarn install --frozen-lockfile; | ||
- name: Run webpacker setup | ||
env: | ||
RAILS_ENV: test | ||
DB_PASSWORD: root | ||
DB_PORT: ${{ job.services.mysql.ports[3306] }} | ||
run: bundle exec rails g webpacker:install && bundle exec rails g webpacker:install:react && bundle exec rails g react:install | ||
- name: "Comment System Tests" | ||
env: | ||
RAILS_ENV: test | ||
DB_PASSWORD: root | ||
DB_PORT: ${{ job.services.mysql.ports[3306] }} | ||
REDIS_HOST: localhost | ||
REDIS_PORT: 6379 | ||
run: | | ||
export DISPLAY=:99 | ||
chromedriver --url-base=/wd/hub & | ||
bundle exec rails test test/comment_system_tests | ||
- name: Archive system test screenshots | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: system-test-screenshots | ||
path: tmp/screenshots/* | ||
|
||
remove-labels: | ||
runs-on: ubuntu-latest | ||
needs: [add-label, unit-tests, functional-tests, integration-tests, system-tests] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters