---
loader: taskgraph.loader.transform:loader
transforms:
    - fenix_taskgraph.transforms.raptor:transforms
    - fenix_taskgraph.transforms.notify:transforms
    - taskgraph.transforms.job:transforms
    - taskgraph.transforms.task:transforms

kind-dependencies:
    - signing
    - toolchain

only-for-build-types:
    - nightly

only-for-abis:
    - armeabi-v7a
    - arm64-v8a

job-defaults:
    attributes:
        nightly: true
        retrigger: true
    dependencies:
        geckoview-nightly: geckoview-nightly
    notify:
        by-level:
            '3':
                email:
                    content: This calls for an action of the Performance team. Use the link to view it on Treeherder.
                    link:
                        text: Treeherder Job
                        href: 'https://treeherder.mozilla.org/#/jobs?repo={product_name}&revision={head_rev}&searchStr={task_name}'
                    on-reasons: [failed]
                    subject: '[{product_name}] Raptor job "{task_name}" failed'
                    to-addresses: [perftest-alerts@mozilla.com]
            default: {}
    run-on-tasks-for: []
    treeherder:
        kind: test
        tier: 1
        platform:
            by-abi:
                arm64-v8a: android-hw-p2-8-0-android-aarch64/opt
                armeabi-v7a: android-hw-g5-7-0-arm7-api-16/opt
    worker-type:
        by-abi:
            armeabi-v7a: t-bitbar-gw-perf-g5
            arm64-v8a: t-bitbar-gw-perf-p2
    worker:
        max-run-time: 3600
        env:
            GECKO_HEAD_REPOSITORY: "https://hg.mozilla.org/mozilla-central"
            MOZ_AUTOMATION: "1"
            MOZ_HIDE_RESULTS_TABLE: "1"
            MOZ_NO_REMOTE: "1"
            MOZ_NODE_PATH: "/usr/local/bin/node"
            MOZHARNESS_CONFIG: "raptor/android_hw_config.py"
            MOZHARNESS_SCRIPT: "raptor_script.py"
            NEED_XVFB: "false"
            NO_FAIL_ON_TEST_ERRORS: "1"
            XPCOM_DEBUG_BREAK: "warn"
        artifacts:
            - name: public/logs/
              path: workspace/logs
              type: directory

            - name: public/test_info/
              path: workspace/build/blobber_upload_dir
              type: directory
    run:
        using: run-task
        checkout: false
        run-as-root: true
        command:
            - 'bash'
            - './test-linux.sh'
            - '--cfg=mozharness/configs/raptor/android_hw_config.py'
            - '--app=fenix'
            - '--binary=org.mozilla.fenix'
            - '--activity=org.mozilla.fenix.IntentReceiverActivity'
            - '--download-symbols=ondemand'
            - '--no-conditioned-profile'
    fetches:
        toolchain:
            - linux64-minidump-stackwalk

jobs:
    youtube-playback:
        test-name: raptor-youtube-playback
        treeherder:
            symbol: 'Rap(ytp)'
        args:
            by-abi:
                # Bug 1558456 - Stop tracking youtube-playback-test on motoG5 for >1080p cases
                armeabi-v7a:
                    - '--test-url-params=exclude=1,2,9,10,17,18,21,22,26,28,30,32,39,40,47,48,55,56,63,64,71,72,79,80,83,84,89,90,95,96'
                default: []
