Add GitHub Actions workflow for testing #8
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: E2E Tests | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
test: | |
runs-on: macos-13 # Run on the macOS Ventura for iOS testing | |
steps: | |
- uses: actions/checkout@v2 | |
name: Check out the code | |
- name: Install dependencies | |
run: npm ci # Install dependencies using 'npm ci' for CI/CD | |
- name: Install Appium and Drivers | |
run: | | |
npm install -g appium | |
appium driver install xcuitest | |
- name: Start Appium server | |
run: appium --port 4723 --log-level error & | |
- name: Wait for Appium server to start | |
run: sleep 5 | |
- name: Run tests | |
env: | |
LINKEDIN_USERNAME: ${{ secrets.LINKEDIN_USERNAME }} | |
LINKEDIN_PASSWORD: ${{ secrets.LINKEDIN_PASSWORD }} | |
run: npm test # Run test script defined in package.json |