Skip to content

Instantly share code, notes, and snippets.

@leosuncin
Last active August 17, 2020 03:12
Show Gist options
  • Save leosuncin/65bcb177ad6629f496900d4763a84220 to your computer and use it in GitHub Desktop.
Save leosuncin/65bcb177ad6629f496900d4763a84220 to your computer and use it in GitHub Desktop.
name: E2E test
on: [push]
jobs:
e2e-test:
runs-on: ubuntu-latest
services:
maildev:
image: maildev/maildev
env:
MAILDEV_INCOMING_USER: admin@example.com
MAILDEV_INCOMING_PASS: He7CdB3XBOees
options: --health-cmd "wget -q -O- http://localhost/healthz || exit 1" --health-interval 10s --health-timeout 5s --health-retries 5 # Use double quotes instead of single quote, or the command will be executed by GitHub Action
ports:
- 1025:25
- 1080:80
steps:
- uses: actions/checkout@v2
- uses: bahmutov/npm-install@v1
- name: Run E2E tests
run: |
npm run test:e2e
env:
CI: 'true'
SMTP_SERVER: localhost
SMTP_PORT: ${{ job.services.maildev.ports[25] }} # Use port exposed by maildev/maildev instead of local port (1025)
SMTP_LOGIN: admin@example.com
SMTP_PASSWORD: He7CdB3XBOees
SMTP_SECURE: 'false'
@leosuncin
Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment