Skip to content

Commit

Permalink
test baseline
Browse files Browse the repository at this point in the history
  • Loading branch information
makeevrserg committed Jul 18, 2024
1 parent 0e963a8 commit 6875108
Showing 1 changed file with 20 additions and 20 deletions.
40 changes: 20 additions & 20 deletions .github/workflows/call-create-baseline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,25 +61,6 @@ jobs:
baseline_file_path="./instances/android/app/src/${build_variant}/generated/baselineProfiles/baseline-prof.txt"
echo "BASELINE_FILE_PATH=${baseline_file_path}" >> $GITHUB_OUTPUT
# steps.create_baseline_task.outputs.BASELINE_TASK
- id: create_baseline_task
run: |
build_variant_uppercase=${{ steps.create_uppercase_variant.outputs.BUILD_VARIANT_NAME_UPPERCASE }}
no_test_param="-P android.testInstrumentationRunnerArguments.androidx.benchmark.enabledRules=BaselineProfile"
task_name="generate${{ steps.create_uppercase_variant.outputs.BUILD_VARIANT_NAME_UPPERCASE }}BaselineProfile"
path=":instances:android:app"
gradlew_full_task="$path:$task_name $no_test_param --stacktrace"
echo "BASELINE_TASK=$gradlew_full_task" >> $GITHUB_OUTPUT
# print all outputs
- name: Print outputs of current baseline task
run: |
echo "BUILD_VARIANT_NAME ${{ steps.create_uppercase_variant.outputs.BUILD_VARIANT_NAME }}"
echo "BUILD_VARIANT_NAME_UPPERCASE ${{ steps.create_uppercase_variant.outputs.BUILD_VARIANT_NAME_UPPERCASE }}"
echo "BASELINE_FILE_ID ${{ steps.create_baseline_file_id.outputs.BASELINE_FILE_ID }}"
echo "BASELINE_FILE_PATH ${{ steps.create_baseline_file_path.outputs.BASELINE_FILE_PATH }}"
echo "BASELINE_TASK ${{ steps.create_baseline_task.outputs.BASELINE_TASK }}"
- name: Setup libx11
run: |
export DEBIAN_FRONTEND=noninteractive;
Expand All @@ -104,9 +85,28 @@ jobs:
sudo echo ${{ steps.share_android_home.ANDROID_HOME }}
sudo ls ${{ steps.share_android_home.ANDROID_HOME }}
# steps.create_baseline_task.outputs.BASELINE_TASK
- id: create_baseline_task
run: |
build_variant_uppercase=${{ steps.create_uppercase_variant.outputs.BUILD_VARIANT_NAME_UPPERCASE }}
no_test_param="-P android.testInstrumentationRunnerArguments.androidx.benchmark.enabledRules=BaselineProfile"
task_name="generate${{ steps.create_uppercase_variant.outputs.BUILD_VARIANT_NAME_UPPERCASE }}BaselineProfile"
path=":instances:android:app"
gradlew_full_task="$path:$task_name $no_test_param --stacktrace"
echo "BASELINE_TASK=ANDROID_SDK_ROOT=${{ steps.share_android_home.ANDROID_HOME }} ANDROID_HOME=${{ steps.share_android_home.ANDROID_HOME }} ANDROID_AVD_HOME=${{ steps.share_android_home.ANDROID_HOME }}/avd $gradlew_full_task" >> $GITHUB_OUTPUT
# print all outputs
- name: Print outputs of current baseline task
run: |
echo "BUILD_VARIANT_NAME ${{ steps.create_uppercase_variant.outputs.BUILD_VARIANT_NAME }}"
echo "BUILD_VARIANT_NAME_UPPERCASE ${{ steps.create_uppercase_variant.outputs.BUILD_VARIANT_NAME_UPPERCASE }}"
echo "BASELINE_FILE_ID ${{ steps.create_baseline_file_id.outputs.BASELINE_FILE_ID }}"
echo "BASELINE_FILE_PATH ${{ steps.create_baseline_file_path.outputs.BASELINE_FILE_PATH }}"
echo "BASELINE_TASK ${{ steps.create_baseline_task.outputs.BASELINE_TASK }}"
- name: Run baseline profiles
run: |
sudo ANDROID_SDK_ROOT=${{ steps.share_android_home.ANDROID_HOME }} ANDROID_HOME=${{ steps.share_android_home.ANDROID_HOME }} ANDROID_AVD_HOME=${{ steps.share_android_home.ANDROID_HOME }}/avd ./gradlew ${{ steps.create_baseline_task.outputs.BASELINE_TASK }}
sudo ./gradlew ${{ steps.create_baseline_task.outputs.BASELINE_TASK }}
- uses: actions/upload-artifact@master
name: "Upload baseline file"
Expand Down

0 comments on commit 6875108

Please sign in to comment.