Skip to content

summarize-topic: Fix linting errors. #415

summarize-topic: Fix linting errors.

summarize-topic: Fix linting errors. #415

Workflow file for this run

# This file is largely copied from the Zulip server's continuous
# integration. The intent is to run the Zulip server's API
# documentation test suite using the current version of this project,
# to verify that the API client is generally compatible with the old
# server release.
name: Zulip server CI
on: [push, pull_request]
defaults:
run:
shell: bash
jobs:
tests:
strategy:
fail-fast: false
matrix:
include:
# Bullseye ships with Python 3.9.2.
- docker_image: zulip/ci:bullseye
name: Debian 11 (Python 3.9, backend)
os: bullseye
legacy_client_interface: "4"
server_version: refs/tags/4.0
# Ubuntu 22.04 ships with Python 3.10.6.
- docker_image: zulip/ci:jammy
name: Ubuntu 22.04 (Python 3.10, backend)
os: jammy
legacy_client_interface: "6"
server_version: refs/tags/6.0
# Debian 12 ships with Python 3.11.2.
- docker_image: zulip/ci:bookworm
name: Debian 12 (Python 3.11, backend + documentation)
os: bookworm
legacy_client_interface: "7"
server_version: refs/tags/7.0
# Ubuntu 24.04 ships with Python 3.12.3.
- docker_image: zulip/ci:noble
name: Ubuntu 24.04 (Python 3.12, backend)
os: noble
legacy_client_interface: "8"
server_version: refs/tags/8.5
runs-on: ubuntu-latest
name: ${{ matrix.name }} (Zulip ${{matrix.server_version}})
container: ${{ matrix.docker_image }}
env:
# GitHub Actions sets HOME to /github/home which causes
# problem later in provison and frontend test that runs
# tools/setup/postgresql-init-dev-db because of the .pgpass
# location. PostgreSQL (psql) expects .pgpass to be at
# /home/github/.pgpass and setting home to `/home/github/`
# ensures it written there because we write it to ~/.pgpass.
HOME: /home/github/
steps:
- name: "Check out python-zulip-api"
uses: actions/checkout@v4
with:
path: api
- name: "Check out Zulip server ${{ matrix.server_version }}"
uses: actions/checkout@v4
with:
repository: zulip/zulip
ref: ${{ matrix.server_version }}
path: server
- name: Install dependencies
run: |
cd server
# This is the main setup job for the test suite
./tools/ci/setup-backend --skip-dev-db-build
# Cleaning caches is mostly unnecessary in GitHub Actions, because
# most builds don't get to write to the cache.
# scripts/lib/clean_unused_caches.py --verbose --threshold 0
- name: Replace dependency with the latest python-zulip-api
run: |
cd server
source tools/ci/activate-venv
pip install ../api/zulip
pip install ../api/zulip_bots
- name: Run documentation and api tests
run: |
cd server
source tools/ci/activate-venv
./tools/test-api
env:
LEGACY_CLIENT_INTERFACE_FROM_SERVER_DOCS_VERSION: ${{ matrix.legacy_client_interface }}
- name: Run backend tests
run: |
cd server
source tools/ci/activate-venv
./tools/test-backend zerver.tests.test_bots zerver.tests.test_embedded_bot_system
env:
LEGACY_CLIENT_INTERFACE_FROM_SERVER_DOCS_VERSION: ${{ matrix.legacy_client_interface }}