Skip to content

Commit

Permalink
feat: updating test lane to use fastlane
Browse files Browse the repository at this point in the history
  • Loading branch information
OdisBy committed Jun 3, 2024
1 parent 0a2b03a commit 2b650ea
Show file tree
Hide file tree
Showing 3 changed files with 52 additions and 33 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/android-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Tests

on:
pull_request:
branches:
- '*'

jobs:
android_build_and_test:
name: Android - run tests
runs-on: ubuntu-22.04
env:
isCI: "true"

steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Set up JDK 17
uses: actions/setup-java@v3
with:
distribution: adopt
java-version: "17"

- name: Install Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: 3.2.3

- name: Add current platform to Bundler lockfile
run: |
bundle lock --add-platform ruby
bundle lock --add-platform x86_64-linux
- name: Install Gems
run: bundle install

- name: Run Tests
run: bundle exec fastlane test
env:
BASE_URL: ${{ secrets.BASE_URL_DEBUG }}
32 changes: 0 additions & 32 deletions .github/workflows/build-and-test.yml

This file was deleted.

10 changes: 9 additions & 1 deletion fastlane/Fastfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,15 @@ QA = "QA"
platform :android do
desc "Runs all the tests"
lane :test do
gradle(task: "test")
# Function:
# This lane run tests with properties BASE_URL
gradle(
task: "test",
print_command: false,
properties: {
"BASE_URL" => ENV['BASE_URL']
}
)
end

desc "Build and Deploy QA version on Firebase App Distribution"
Expand Down

0 comments on commit 2b650ea

Please sign in to comment.