diff --git a/.github/workflows/ci.yml b/.github/workflows/build.yml similarity index 83% rename from .github/workflows/ci.yml rename to .github/workflows/build.yml index 6a25f275..5bbc482e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/build.yml @@ -1,16 +1,16 @@ # For documentation on GitHub Actions Workflows, see: # https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions -name: CI +name: "build" on: [ push, pull_request ] jobs: - ci: + build: strategy: + fail-fast: false matrix: os: [ ubuntu-latest, macos-latest, windows-latest ] python-version: [ "3.8", "3.9", "3.10", "3.11", "3.12", "3.13" ] - fail-fast: false runs-on: ${{ matrix.os }} steps: - uses: actions/checkout@v4 # https://github.com/actions/checkout @@ -18,13 +18,12 @@ jobs: # Only a single commit is fetched by default, for the ref/SHA that triggered the workflow. # Set fetch-depth: 0 to fetch all history for all branches and tags. fetch-depth: 0 # Needed for setuptools_scm to work correctly - - name: Set up Python - uses: actions/setup-python@v5 # https://github.com/actions/setup-python + - uses: actions/setup-python@v5 # https://github.com/actions/setup-python with: python-version: ${{ matrix.python-version }} allow-prereleases: true - - name: Install python prerequisites - run: pip install -U --user pip setuptools setuptools-scm nox + - name: Install dependencies + run: python -m pip install --upgrade pip setuptools setuptools-scm nox - name: Run tests and post coverage results env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/pyproject.toml b/pyproject.toml index 189d5292..3d4298d8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,6 +48,18 @@ warn_return_any = true warn_unreachable = true warn_unused_ignores = false +[tool.pytest.ini_options] +testpaths = [ + "tests", + "tests_isolated", +] +addopts = [ + "--cov=cmd2", + "--cov-append", + "--cov-report=term", + "--cov-report=html", +] + [tool.ruff] # Exclude a variety of commonly ignored directories. exclude = [ diff --git a/setup.cfg b/setup.cfg deleted file mode 100644 index 8e539d0c..00000000 --- a/setup.cfg +++ /dev/null @@ -1,8 +0,0 @@ -[tool:pytest] -testpaths = - tests -addopts = - --cov=cmd2 - --cov-append - --cov-report=term - --cov-report=html