Skip to content

Commit

Permalink
Pipeline Continuous Testing BrowserStack
Browse files Browse the repository at this point in the history
  • Loading branch information
thinogueiras committed Mar 16, 2024
1 parent 63d1e71 commit 3766b0b
Show file tree
Hide file tree
Showing 3 changed files with 47 additions and 7 deletions.
42 changes: 42 additions & 0 deletions .github/workflows/continuous-testing.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: BrowserStack Tests

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

workflow_dispatch:

env:
BROWSERSTACK_USERNAME: ${{ secrets.BROWSERSTACK_USERNAME }}
BROWSERSTACK_ACCESS_KEY: ${{ secrets.BROWSERSTACK_ACCESS_KEY }}

jobs:
tests:
runs-on: ubuntu-latest
name: Android Tests

steps:
- uses: actions/checkout@v4
- name: Set up JDK 11
uses: actions/setup-java@v4
with:
java-version: '11'
distribution: 'temurin'
cache: maven

- name: Build
run: mvn clean compile

- name: Run Tests
run: mvn test

- name: Upload Reports
uses: actions/upload-artifact@v4
if: always()
with:
name: Allure Reports
path: "**/allure-results/"
retention-days: 90
if-no-files-found: warn
8 changes: 3 additions & 5 deletions browserstack.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
userName: ${{ secrets.BROWSERSTACK_USERNAME }}
accessKey: ${{ secrets.BROWSERSTACK_ACCESS_KEY }}
userName: $BROWSERSTACK_USERNAME
accessKey: $BROWSERSTACK_ACCESS_KEY
framework: junit5
app: app/yodapp-beta.apk
platforms:
Expand All @@ -12,13 +12,11 @@ platforms:
- platformName: android
deviceName: Motorola Moto G71 5G
platformVersion: 11.0
parallelsPerPlatform: 1
parallelsPerPlatform: 5
browserstackLocal: false
buildName: junit5-appium
buildIdentifier: ${BUILD_NUMBER}
projectName: Yodapp Android
testObservability: true
networkLogs: true
consoleLogs: info

source: junit5:appium-eclipse:v1.0.8
4 changes: 2 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<maven.compiler.target>11</maven.compiler.target>
<maven.compiler.source>11</maven.compiler.source>
<surefire.plugin.version>3.0.0-M5</surefire.plugin.version>
<config.file>qa/thinogueiras/appium/tests/ClickTest.java</config.file>
<config.file>qa/thinogueiras/appium/tests/RadioTest.java</config.file>
</properties>

<dependencies>
Expand All @@ -33,7 +33,7 @@
<dependency>
<groupId>io.appium</groupId>
<artifactId>java-client</artifactId>
<version>9.0.0</version>
<version>9.2.0</version>
</dependency>
<dependency>
<groupId>io.qameta.allure</groupId>
Expand Down

0 comments on commit 3766b0b

Please sign in to comment.