summaryrefslogtreecommitdiff
path: root/tf-tftf-gerrit-tforg-l1.yaml
blob: ed90cc7160f1e9fc8f3cd5193c3935e9a37be832 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
- job:
    name: tf-tftf-gerrit-tforg-l1
    node: master
    project-type: multijob
    concurrent: true
    disabled: false
    description: |
      Job that triggers for every TF-A-Tests patch approved with the Allow-CI+1
      label on review.trustedfirmware.org.
    properties:
    - throttle:
        option: project
        enabled: true
        max-total: 5
    - build-discarder:
        days-to-keep: 180
        num-to-keep: 180
    - authorization:
        !include: authorization.yaml.inc
    parameters:
        - string:
            name: GERRIT_PROJECT
            default: 'TF-A/tf-a-tests'
        - string:
            name: GERRIT_BRANCH
            default: 'refs/heads/master'
        - string:
            name: GERRIT_REFSPEC
            default: '+refs/heads/master:refs/remotes/origin/master'
        - string:
            name: GERRIT_PATCHSET_NUMBER
            default: ''
        - string:
            name: GERRIT_CHANGE_NUMBER
            default: ''
    wrappers:
      - credentials-binding:
          - ssh-user-private-key:
              credential-id: TFA_CI_BOT_USER_SSH_KEY
              key-file-variable: CI_BOT_KEY
              username-variable: CI_BOT_USERNAME
              passphrase-variable: ''
      - workspace-cleanup
      - timestamps
    builders:
    - shell: |
        #!/bin/bash
        set -e
        cat << EOF > env.param
        GERRIT_PATCHSET_NUMBER=${GERRIT_PATCHSET_NUMBER}
        GERRIT_CHANGE_NUMBER=${GERRIT_CHANGE_NUMBER}
        GERRIT_HOST=${GERRIT_HOST}
        QA_SERVER_PROJECT=${JOB_NAME}
        QA_SERVER_VERSION=${BUILD_NUMBER}
        TFTF_GERRIT_PROJECT=${GERRIT_PROJECT}
        TFTF_GERRIT_BRANCH=${GERRIT_BRANCH}
        TFTF_GERRIT_REFSPEC=${GERRIT_REFSPEC}
        EOF
    - multijob:
        condition: COMPLETED
        name: Build and static checks
        projects:
        - kill-phase-on: NEVER
          name: tf-ci-gateway
          predefined-parameters: |-
            TEST_GROUPS=tf-l2-scan-build
            ENABLE_STATIC_CHECK=true
            REPO_UNDER_STATIC_CHECK=tf-a-tests
          property-file: env.param
    - multijob:
        condition: COMPLETED
        name: Run doc build check
        projects:
        - kill-phase-on: NEVER
          name: tf-ci-gateway
          predefined-parameters: |
            TEST_GROUPS=tftf-l1-check-docs
          property-file: env.param
    - multijob:
        condition: COMPLETED
        name: Build TF-A-Tests
        projects:
        - kill-phase-on: NEVER
          name: tf-ci-gateway
          predefined-parameters: |
            TEST_GROUPS=tftf-l1-build
          property-file: env.param
    - multijob:
        condition: COMPLETED
        name: Basic TF-A-Tests test cases
        projects:
        - kill-phase-on: NEVER
          name: tf-ci-gateway
          predefined-parameters: |
            TEST_GROUPS=tftf-l1-fvp tftf-l1-juno
          property-file: env.param
    triggers:
    - gerrit:
        server-name: review.trustedfirmware.org
        trigger-on:
          - comment-added-event:
              approval-category: "Allow-CI"
              approval-value: 1
        projects:
          - project-compare-type: PLAIN
            project-pattern: TF-A/tf-a-tests
            branches:
            - branch-compare-type: PLAIN
              branch-pattern: master