mirror of
https://github.com/Freika/dawarich.git
synced 2026-01-10 17:21:38 -05:00
Update CI workflow
This commit is contained in:
parent
8bb966b546
commit
a003191a71
3 changed files with 33 additions and 37 deletions
|
|
@ -1 +0,0 @@
|
||||||
MAPBOX_ACCESS_TOKEN=MAPBOX_ACCESS_TOKEN
|
|
||||||
68
.github/workflows/ci.yml
vendored
68
.github/workflows/ci.yml
vendored
|
|
@ -1,53 +1,51 @@
|
||||||
# .github/workflows/ruby.yml
|
name: CI
|
||||||
name: Ruby
|
|
||||||
|
|
||||||
on:
|
on:
|
||||||
|
pull_request:
|
||||||
push:
|
push:
|
||||||
branches: [main]
|
branches: [main]
|
||||||
pull_request:
|
|
||||||
branches: [main]
|
|
||||||
|
|
||||||
env:
|
|
||||||
POSTGRES_DB: postgres
|
|
||||||
POSTGRES_USER: postgres
|
|
||||||
POSTGRES_PASSWORD: password
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
tests:
|
test:
|
||||||
name: Tests
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
services:
|
services:
|
||||||
postgres:
|
postgres:
|
||||||
image: postgres:12
|
image: postgres
|
||||||
env:
|
env:
|
||||||
POSTGRES_PASSWORD: password
|
POSTGRES_USER: postgres
|
||||||
ports: ['5432:5432']
|
POSTGRES_PASSWORD: postgres
|
||||||
options: >-
|
ports:
|
||||||
--health-cmd pg_isready
|
- 5432:5432
|
||||||
--health-interval 10s
|
options: --health-cmd="pg_isready" --health-interval=10s --health-timeout=5s --health-retries=3
|
||||||
--health-timeout 5s
|
|
||||||
--health-retries 5
|
|
||||||
steps:
|
|
||||||
- name: Checkout code
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
|
|
||||||
- name: Setup Ruby
|
steps:
|
||||||
|
- name: Install packages
|
||||||
|
run: sudo apt-get update && sudo apt-get install --no-install-recommends -y google-chrome-stable curl libjemalloc2 libvips postgresql-client libpq-dev
|
||||||
|
|
||||||
|
- name: Checkout code
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: Set up Ruby
|
||||||
uses: ruby/setup-ruby@v1
|
uses: ruby/setup-ruby@v1
|
||||||
with:
|
with:
|
||||||
ruby-version: 3.2.3
|
ruby-version: .ruby-version
|
||||||
bundler-cache: true
|
bundler-cache: true
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Run tests
|
||||||
run: |
|
|
||||||
sudo apt-get update && sudo apt-get -yqq install libpq-dev
|
|
||||||
bundle install --jobs 4 --retry 3
|
|
||||||
- name: Run Tests
|
|
||||||
env:
|
env:
|
||||||
RAILS_ENV: test
|
RAILS_ENV: test
|
||||||
PGHOST: localhost
|
DATABASE_URL: postgres://postgres:postgres@localhost:5432
|
||||||
DISABLE_SPRING: 1
|
run: bin/rails db:setup spec
|
||||||
run: |
|
|
||||||
cp config/database.ci.yml config/database.yml
|
- name: Keep screenshots from failed system tests
|
||||||
bundle exec rails db:schema:load
|
uses: actions/upload-artifact@v4
|
||||||
bundle exec rspec --format progress
|
if: failure()
|
||||||
|
with:
|
||||||
|
name: screenshots
|
||||||
|
path: ${{ github.workspace }}/tmp/capybara
|
||||||
|
if-no-files-found: ignore
|
||||||
|
- name: Upload coverage reports to Codecov
|
||||||
|
uses: codecov/codecov-action@v4.0.1
|
||||||
|
with:
|
||||||
|
token: ${{ secrets.CODECOV_TOKEN }}
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,6 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
|
||||||
- Visits page. This page will show you all your visits, calculated based on the areas you've created. You can see the date and time of the visit, the area you've visited, and the duration of the visit.
|
- Visits page. This page will show you all your visits, calculated based on the areas you've created. You can see the date and time of the visit, the area you've visited, and the duration of the visit.
|
||||||
- A possibility to confirm or decline a visit. When you create an area, the visit is not calculated immediately. You need to confirm or decline the visit. You can do this on the Visits page. Click on the visit, then click on the "Confirm" or "Decline" button. If you confirm the visit, it will be added to your timeline. If you decline the visit, it will be removed from your timeline.
|
- A possibility to confirm or decline a visit. When you create an area, the visit is not calculated immediately. You need to confirm or decline the visit. You can do this on the Visits page. Click on the visit, then click on the "Confirm" or "Decline" button. If you confirm the visit, it will be added to your timeline. If you decline the visit, it will be removed from your timeline.
|
||||||
- Settings for visit calculation. You can set the minimum time spent in the area to consider it as a visit. This setting can be found in the Settings page.
|
- Settings for visit calculation. You can set the minimum time spent in the area to consider it as a visit. This setting can be found in the Settings page.
|
||||||
- [ ] Tests
|
|
||||||
- [x] Swagger doc for Areas endpoint
|
- [x] Swagger doc for Areas endpoint
|
||||||
- [ ] Atomicity for visits creation
|
- [ ] Atomicity for visits creation
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue