blob: 55572036c3fb7f6309ccae9bcf97b320e9b9d9e6 [file] [log] [blame]
Arthur She499da002023-10-11 09:04:39 -07001#!/usr/bin/env bash
2#
3# Copyright (c) 2023 Arm Limited. All rights reserved.
4#
5# SPDX-License-Identifier: BSD-3-Clause
6#
7
8# Generate a YAML file in order to dispatch Corsola Chromebook runs on LAVA. Note that
9# this script would produce a meaningful output when run via. Jenkins.
10#
11# $bin_mode must be set. This script outputs to STDOUT
12
13ci_root="$(readlink -f "$(dirname "$0")/..")"
14source "$ci_root/utils.sh"
15
16get_bl31_url() {
17 local bin_mode="${bin_mode:?}"
18
19 if upon "$jenkins_run"; then
20 echo "$jenkins_url/job/$JOB_NAME/$BUILD_NUMBER/artifact/artefacts/$bin_mode/bl31.elf"
21 else
22 echo "file://$workspace/artefacts/$bin_mode/bl31.elf"
23 fi
24}
25
26bl31_url="${bl31_url:-$(get_bl31_url)}"
27
28build_mode=$(echo $bin_mode | tr '[:lower:]' '[:upper:]')
29
30cat <<EOF
31device_type: mt8186-corsola-tentacruel
32job_name: MT8186 Corsola Chromebook BL31 depthcharge boot test - $build_mode
33timeouts:
34 job:
35 minutes: 30
36 action:
37 minutes: 15
38 connection:
39 minutes: 5
40priority: medium
41visibility: public
42actions:
43- deploy:
44 timeout:
45 minutes: 5
46 to: flasher
47 images:
48 image:
49 url: https://images.validation.linaro.org/people.linaro.org/~arthur.she/images/chromebook/corsola/tentacruel_tf-a-ci_golden_image.bin.gz
50 bl31:
51 url: $bl31_url
52- boot:
53 timeout:
54 minutes: 5
55 method: minimal
56- test:
57 timeout:
58 minutes: 15
59 interactive:
60 - name: int_1
61 prompts: ["Starting depthcharge on Tentacruel"]
62 script:
63 - command:
64 - name: int_2
65 prompts: ["This is a TF-A test build. Halting"]
66 script:
67 - command: