Skip to content

Add GitHub Actions workflow for E2E testing with Docker #1

Add GitHub Actions workflow for E2E testing with Docker

Add GitHub Actions workflow for E2E testing with Docker #1

Workflow file for this run

# Name of our workflow (will show up in the "Actions" tab)
name: E2E Test Suite
# --- Triggers ---
# This tells GitHub *when* to run this workflow
on:
# Run on every push to the 'main' branch
push:
branches: [ "main" ]
# Also allow running it manually from the Actions tab
workflow_dispatch:
# --- Jobs ---
# A workflow is made of one or more "jobs"
jobs:
build-and-test:
# The type of server to run on (GitHub-hosted)
# 'ubuntu-latest' comes with Docker pre-installed
runs-on: ubuntu-latest
steps:
# Step 1: Check out our repository code
- name: Check out repository
uses: actions/checkout@v4
# Step 2: Build and run our Docker containers
# This is the *exact* command we've been using!
- name: Run E2E Tests with Docker Compose
run: docker-compose up --build --abort-on-container-exit
# Step 3: Upload Allure results as an artifact
# This saves the 'allure-results' folder from the server
# so we can download it later.
- name: Upload Allure results
uses: actions/upload-artifact@v4
with:
name: allure-results
path: allure-results/