add 'trove_search_in_flats' feature flag #273
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
name: run_share_tests | |
on: | |
push: | |
pull_request: | |
workflow_dispatch: | |
permissions: | |
checks: write # for coveralls | |
jobs: | |
run_tests: | |
strategy: | |
fail-fast: false | |
matrix: | |
python-version: ['3.10'] # TODO: 3.11, 3.12 | |
postgres-version: ['10', '15'] | |
runs-on: ubuntu-latest | |
services: | |
postgres: | |
image: postgres:${{ matrix.postgres-version }} | |
env: | |
POSTGRES_PASSWORD: postgres | |
# Set health checks to wait until postgres has started | |
options: >- | |
--health-cmd pg_isready | |
--health-interval 10s | |
--health-timeout 5s | |
--health-retries 5 | |
ports: | |
- 5432:5432 | |
elasticsearch8: | |
image: elasticsearch:8.7.0 | |
env: | |
xpack.security.enabled: false | |
node.name: singlenode | |
cluster.initial_master_nodes: singlenode | |
ports: | |
- 9208:9200 | |
elasticsearch5: | |
image: elasticsearch:5.4 | |
env: | |
ES_JAVA_OPTS: "-Xms512m -Xmx512m" | |
ports: | |
- 9205:9200 | |
rabbitmq: | |
image: rabbitmq:management | |
ports: | |
- 5672:5672 | |
- 15672:15672 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: install non-py dependencies | |
run: sudo apt-get update && sudo apt-get install -y libxml2-dev libxslt1-dev libpq-dev git gcc | |
- name: set up python${{ matrix.python-version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
cache: pip | |
cache-dependency-path: | | |
requirements.txt | |
dev-requirements.txt | |
- name: install py dependencies | |
run: pip install -r dev-requirements.txt | |
- name: install share | |
run: python setup.py develop | |
- name: flake it | |
run: flake8 . | |
- name: run tests | |
run: | | |
coverage run -m pytest -x --create-db | |
coverage run --append -m behave | |
env: | |
DATABASE_PASSWORD: postgres | |
ELASTICSEARCH8_URL: http://localhost:9208/ | |
ELASTICSEARCH5_URL: http://localhost:9205/ | |
- name: coveralls | |
uses: coverallsapp/github-action@v2 |