Skip to content

#547 Fix AG-UI event types #1562

#547 Fix AG-UI event types

#547 Fix AG-UI event types #1562

Workflow file for this run

name: Tests
on:
push:
branches:
- '*.x'
pull_request:
jobs:
ci:
runs-on: ${{ matrix.os }}
services:
qdrant:
image: qdrant/qdrant:latest
ports:
- 6333:6333
- 6334:6334
chroma:
image: chromadb/chroma:latest
ports:
- 8000:8000
mailisearch:
image: getmeili/meilisearch:latest
ports:
- 7700:7700
mysql:
image: mysql:8.0
env:
MYSQL_ALLOW_EMPTY_PASSWORD: yes
MYSQL_DATABASE: neuron-ai
ports:
- 3306:3306
options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3
opensearch:
image: opensearchproject/opensearch:${{ matrix.opensearch-version || 'latest' }}
ports:
- 9201:9200 # Avoid port conflict with Elasticsearch
- 9600:9600
env:
discovery.type: single-node
plugins.security.disabled: "true"
DISABLE_INSTALL_DEMO_CONFIG: true
options: --health-cmd="curl -s http://localhost:9200/_cluster/health | grep '\"status\":\"green\"'" --health-interval=10s --health-timeout=5s --health-retries=5
neo4j:
image: neo4j:5.26.19-ubi9
ports:
- 7687:7687
- 7474:7474
env:
NEO4J_AUTH: none
strategy:
matrix:
os: [ubuntu-latest]
php: ['8.1', '8.2', '8.3', '8.4', '8.5']
dependency-version: [prefer-lowest, prefer-stable]
opensearch-version: ['latest']
include:
- os: ubuntu-latest
php: '8.5'
dependency-version: prefer-stable
opensearch-version: '3.5.0'
name: PHP ${{ matrix.php }} - ${{ matrix.os }} - ${{ matrix.dependency-version }}
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Login to Docker Hub
uses: docker/login-action@v4
# This condition skips the step if the event is a Pull Request
if: github.event_name != 'pull_request'
with:
username: ${{ vars.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Install poppler-utils (for pdftotext)
run: |
sudo apt-get update
sudo apt-get install -y poppler-utils
- name: Verify pdftotext installation
run: pdftotext -v
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
coverage: none
- name: Setup Problem Matches
run: |
echo "::add-matcher::${{ runner.tool_cache }}/php.json"
echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json"
- name: Configure sysctl limits (for elastic to boot)
run: |
sudo swapoff -a
sudo sysctl -w vm.swappiness=1
sudo sysctl -w fs.file-max=262144
sudo sysctl -w vm.max_map_count=262144
- name: Runs Elasticsearch
uses: elastic/elastic-github-actions/elasticsearch@master
with:
stack-version: 8.17.0
security-enabled: false
- name: Install Typesense Database
run: |
docker run -id \
-p 8108:8108 \
--name typesense \
-v /tmp/typesense-data:/data \
-v /tmp/typesense-analytics-data:/analytics-data \
typesense/typesense:28.0 \
--api-key=xyz \
--data-dir=/data \
--enable-search-analytics=true \
--analytics-dir=/analytics-data \
--analytics-flush-interval=60 \
--analytics-minute-rate-limit=100 \
--enable-cors
- name: Wait for Typesense to be healthy
shell: bash
run: |
start_time=$(date +%s)
timeout=60
counter=0
until curl -s http://localhost:8108/health | grep -q '"ok":true'; do
if [ $counter -eq $timeout ]; then
echo "Timed out waiting for Typesense to be healthy"
exit 1
fi
echo "Waiting for Typesense to be healthy..."
sleep 5
counter=$((counter + 1))
done
end_time=$(date +%s)
elapsed=$((end_time - start_time))
echo "Typesense healthcheck elapsed: ${elapsed}s"
- name: Install PHP dependencies
run: composer update --${{ matrix.dependency-version }} --no-interaction --no-progress --ansi
- name: Unit Tests
run: vendor/bin/phpunit --colors=always
env:
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}