Skip to content

Commit

Permalink
Respond to review feedback
Browse files Browse the repository at this point in the history
* Remove some formatting changes
* Remove pytest importlib config option
* Add mention of support for SQLAlchemy 2 to README
  • Loading branch information
mhauru committed Aug 2, 2023
1 parent f5b6947 commit 25b50b7
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 31 deletions.
56 changes: 28 additions & 28 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,38 +14,38 @@ jobs:
sqlalchemy-version: ["1.4", "2.0"]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
cache: pip
cache-dependency-path: pyproject.toml
- name: Install dependencies SQLAlchemy 1.4
if: matrix.sqlalchemy-version == 1.4
run: pip install -e .[test,sqlmodel] coveralls SQLAlchemy==1.4.*
- name: Install dependencies SQLAlchemy 2.0
if: matrix.sqlalchemy-version == 2.0
run: pip install -e .[test] coveralls SQLAlchemy==2.0.*
- name: Test with pytest
run: coverage run -m pytest
- name: Upload Coverage
run: coveralls --service=github
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COVERALLS_FLAG_NAME: ${{ matrix.test-name }}
COVERALLS_PARALLEL: true
SQLALCHEMY_WARN_20: "true"
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
cache: pip
cache-dependency-path: pyproject.toml
- name: Install dependencies SQLAlchemy 1.4
if: matrix.sqlalchemy-version == 1.4
run: pip install -e .[test,sqlmodel] coveralls SQLAlchemy==1.4.*
- name: Install dependencies SQLAlchemy 2.0
if: matrix.sqlalchemy-version == 2.0
run: pip install -e .[test] coveralls SQLAlchemy==2.0.*
- name: Test with pytest
run: coverage run -m pytest
- name: Upload Coverage
run: coveralls --service=github
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COVERALLS_FLAG_NAME: ${{ matrix.test-name }}
COVERALLS_PARALLEL: true
SQLALCHEMY_WARN_20: "true"

coveralls:
name: Finish Coveralls
needs: [test]
runs-on: ubuntu-latest
container: python:3-slim
steps:
- name: Finished
run: |
pip install coveralls
coveralls --service=github --finish
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Finished
run: |
pip install coveralls
coveralls --service=github --finish
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ latest SQLAlchemy version).
Features
========

* Supports SQLAlchemy 1.4.x
* Supports SQLAlchemy 1.4.x and 2
* Produces declarative code that almost looks like it was hand written
* Produces `PEP 8`_ compliant code
* Accurately determines relationships, including many-to-many, one-to-one
Expand Down
3 changes: 1 addition & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,7 @@ strict = true
plugins = ["sqlalchemy.ext.mypy.plugin"]

[tool.pytest.ini_options]
pythonpath = "src/sqlacodegen"
addopts = "-rsx --tb=short --import-mode=importlib"
addopts = "-rsx --tb=short"
testpaths = ["tests"]

[coverage.run]
Expand Down

0 comments on commit 25b50b7

Please sign in to comment.