From b16d23811693680f787fb642cb4e85cf3db48993 Mon Sep 17 00:00:00 2001 From: Alexander Nesterov Date: Sat, 16 Aug 2025 18:53:22 +0200 Subject: [PATCH 1/2] update workflows: move `device-test-adb` step to reusable workflow --- .github/workflows/bench.yml | 38 ---------------------------- .github/workflows/reusable-ci.yml | 41 +++++++++++++++++++++++++++++++ 2 files changed, 41 insertions(+), 38 deletions(-) diff --git a/.github/workflows/bench.yml b/.github/workflows/bench.yml index 85adffe..d766dce 100644 --- a/.github/workflows/bench.yml +++ b/.github/workflows/bench.yml @@ -20,41 +20,3 @@ jobs: with: os: ${{ matrix.os }} device_serial: ${{ github.event.inputs.device_serial || 'emulator-5554' }} - - # Optional: Run on a self-hosted runner with a real device - device-test-adb: - if: github.event_name == 'workflow_dispatch' || contains(github.event.head_commit.message, '[device-test-adb]') - needs: ci-matrix - runs-on: self-hosted - steps: - - uses: actions/checkout@v4 - - - name: Set up Python - uses: actions/setup-python@v4 - with: - python-version: '3.11' - - - name: Install dependencies - run: | - pip install --upgrade pip - pip install -r requirements.txt - pip install -e . - - - name: Check ADB devices - run: adb devices - - - name: Run minimal benchmark - env: - DEVICE_SERIAL: ${{ github.event.inputs.device_serial || 'emulator-5554' }} - run: | - ovmobilebench list-devices - # Uncomment when ready: - # ovmobilebench all -c experiments/android_example.yaml --dry-run - - - name: Upload results - if: always() - uses: actions/upload-artifact@v4 - with: - name: benchmark-results-adb - path: experiments/results/ - retention-days: 30 diff --git a/.github/workflows/reusable-ci.yml b/.github/workflows/reusable-ci.yml index 729f606..296ef79 100644 --- a/.github/workflows/reusable-ci.yml +++ b/.github/workflows/reusable-ci.yml @@ -157,3 +157,44 @@ jobs: name: benchmark-results-ssh-${{ inputs.os }} path: experiments/results/ retention-days: 30 + + # Optional: Run on a self-hosted runner with a real device + device-test-adb: + # Only run if explicitly triggered and only once (not for each OS in matrix) + if: (github.event_name == 'workflow_dispatch' || contains(github.event.head_commit.message, '[device-test-adb]')) && inputs.os == 'ubuntu-latest' + needs: + - build-package + - dry-run + runs-on: self-hosted + steps: + - uses: actions/checkout@v4 + + - name: Set up Python + uses: actions/setup-python@v4 + with: + python-version: '3.11' + + - name: Install dependencies + run: | + pip install --upgrade pip + pip install -r requirements.txt + pip install -e . + + - name: Check ADB devices + run: adb devices + + - name: Run minimal benchmark + env: + DEVICE_SERIAL: ${{ inputs.device_serial }} + run: | + ovmobilebench list-devices + # Uncomment when ready: + # ovmobilebench all -c experiments/android_example.yaml --dry-run + + - name: Upload results + if: always() + uses: actions/upload-artifact@v4 + with: + name: benchmark-results-adb-${{ inputs.os }} + path: experiments/results/ + retention-days: 30 From 8292e3f9ad9708f37063a35a0975e8bdfccbd615 Mon Sep 17 00:00:00 2001 From: Alexander Nesterov Date: Sat, 16 Aug 2025 18:53:57 +0200 Subject: [PATCH 2/2] update bench workflow: update description for device serial input to 'Mobile device serial' --- .github/workflows/bench.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/bench.yml b/.github/workflows/bench.yml index d766dce..6a1cdc6 100644 --- a/.github/workflows/bench.yml +++ b/.github/workflows/bench.yml @@ -8,7 +8,7 @@ on: workflow_dispatch: inputs: device_serial: - description: 'Android device serial' + description: 'Mobile device serial' required: false jobs: