Flank / flank

:speedboat: Massively parallel Android and iOS test runner for Firebase Test Lab

Home Page:https://firebase.community/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

File does not exist using Flank on an iOS project

JPrendy opened this issue · comments

Describe the bug
Getting a file does not exist when I run Flank for an iOS project using Flank's github action.

To Reproduce
I referred to Firebase's official doc on how to build your XCTest https://firebase.google.com/docs/test-lab/ios/run-xctest?authuser=0#package-app

I used the following xcodebuild script

xcodebuild -project firebase-testing-ios-application.xcodeproj \
-scheme firebase-testing-ios-application \
-derivedDataPath fastlane/buildOutput \
-sdk iphoneos build-for-testing \
-allowProvisioningUpdates

then used the following to zip my project

cd fastlane/buildOutput/Build/Products
zip -r test.zip firebase-testing-ios-application_iphoneos15.4-arm64.xctestrun Debug-iphoneos

I moved my test.zip and firebase-testing-ios-application_iphoneos15.4-arm64.xctestrun to the root of my project.

Called the Flank Github Action with

name: CI pull request

on:
  push: 
    branches:
      - main
  pull_request:
    branches:
      - main


jobs:
  build:

    runs-on: macos-latest
    timeout-minutes: 20

    steps:
    - uses: actions/checkout@v2.3.4

    - name: Create service account
      run: echo '${{ secrets.SERVICE_ACCOUNT }}' > service_account_created.json

    - name: Run Flank
      id: flank_run
      uses: Flank/flank@master
      env: 
        GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
      with:
        service_account: './service_account_created.json'
        platform: ios
        flank_configuration_file: './flank.yml'

My flank.yml file is as follows

gcloud:
  xcode-version: 13.1

  timeout: 20m
  test: ./test.zip
  xctestrun-file: ./firebase-testing-ios-application_iphoneos15.4-arm64.xctestrun

  device:
  - model: iphone8
    version: 12.4
    orientation: portrait
    locale: en_US

I then get the following in my logs

RunTests
Found xctest: /Users/runner/work/firebase-testing-ios-application/firebase-testing-ios-application/Debug-iphoneos/firebase-testing-ios-application.app/PlugIns/firebase-testing-ios-applicationTests.xctest
isMacOS = true (mac os x)


File /Users/runner/work/firebase-testing-ios-application/firebase-testing-ios-application/Debug-iphoneos/firebase-testing-ios-application.app/PlugIns/firebase-testing-ios-applicationTests.xctest/firebase-testing-ios-applicationTests does not exist!

Expected behavior
I was expecting the logs to say the file does exist, as locally I can see the file and it is in the correct path.

SCR-20220404-tzc-2

Details (please complete the following information):
I'm running Flank on Github Actions and I am using the latest Flank version that was released v22.03.0.

Additional context
Since I can see the file is there when I run the xcodebuild statement, I am wondering is there anything I need to configure in my test scheme in order to not see that message saying the file does not exist.