diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 4e8e0fd..b8c3183 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,4 +1,4 @@ -name: Matrix Build +name: Build and Test on: push: branches: diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 5dd7241..e9c9d12 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -7,14 +7,14 @@ on: branches: - "main" jobs: - build: + lint: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - - name: Set up Python ${{ matrix.python-version }} + - name: Set up Python 3.13 uses: actions/setup-python@v3 with: - python-version: ${{ matrix.python-version }} + python-version: 3.13 - name: Install dependencies run: | python -m pip install --upgrade pip diff --git a/Makefile b/Makefile index 5b2fa93..749738e 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -SUBDIRS := $(filter-out src/dbtools-mcp-server src/mysql-mcp-server src/oci-pricing-mcp-server,$(wildcard src/*)) +SUBDIRS := $(filter-out src/dbtools-mcp-server src/mysql-mcp-server src/oci-pricing-mcp-server src/oracle-db-doc-mcp-server,$(wildcard src/*)) .PHONY: test format @@ -42,12 +42,14 @@ lock: fi \ done -test: +lint: uv tool run --from 'tox==4.30.2' tox -e lint + +test: @for dir in $(SUBDIRS); do \ if [ -f $$dir/pyproject.toml ]; then \ echo "Testing $$dir"; \ - cd $$dir && uv run pytest && cd ../..; \ + cd $$dir && uv sync && uv run pytest && cd ../..; \ fi \ done diff --git a/README.md b/README.md index 8bb6ebb..70c8896 100644 --- a/README.md +++ b/README.md @@ -330,6 +330,12 @@ npx @modelcontextprotocol/inspector \ Inspector will run your server on localhost (for instance: http://127.0.0.1:6274) which should automatically open the tool for debugging and development. +### Running tests + +```bash +make lint +make test +``` ## Contributing