Files
Nitzan P 5be68a5b04 Modernize to pyproject.toml and fix test assertion
- Remove requirements.txt and requirements-dev.txt (duplicates pyproject.toml)
- Update Dockerfile to use 'pip install .' instead of requirements.txt
- Update README.md and GitHub workflows to use 'pip install -e .[dev]'
- Fix test_get_valuation_comparables: check for 'deal_date' instead of non-existent 'asset_room_num'
  (rooms field is optional and excluded when None due to exclude_none=True)
- Fix fastmcp version constraint in pyproject.toml (>=2.13.0,<3.0.0)
- Add vcrpy to dev dependencies

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-18 23:00:03 +02:00

81 lines
1.8 KiB
YAML

name: Tests
on:
pull_request:
branches: [ main ]
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.12
uses: actions/setup-python@v5
with:
python-version: "3.12"
cache: 'pip'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -e .[dev]
- name: Run unit tests with coverage
run: |
pytest -v -m "not integration" --cov=nadlan_mcp --cov-report=xml --cov-report=term
continue-on-error: false
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
with:
file: ./coverage.xml
flags: unittests
name: codecov-umbrella
fail_ci_if_error: false
token: ${{ secrets.CODECOV_TOKEN }}
continue-on-error: true
- name: Run integration tests (if configured)
run: |
pytest -v -m integration || echo "Integration tests skipped (requires API access)"
continue-on-error: true
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.13"
cache: 'pip'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -e .[dev]
- name: Run black (check only)
run: |
black --check nadlan_mcp/ tests/
continue-on-error: true
- name: Run isort (check only)
run: |
isort --check-only nadlan_mcp/ tests/
continue-on-error: true
- name: Run flake8
run: |
flake8 nadlan_mcp/ tests/ --max-line-length=120 --extend-ignore=E203,W503
continue-on-error: true
- name: Run mypy
run: |
mypy nadlan_mcp/ --ignore-missing-imports
continue-on-error: true