-
Notifications
You must be signed in to change notification settings - Fork 65
99 lines (86 loc) · 3.53 KB
/
conformance.yaml
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
name: Java Conformance CI
on:
push:
branches:
- main
pull_request:
# Declare default permissions as read only.
permissions: read-all
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
java: [
11.x
# 12.x,
# 13.x
]
steps:
- name: Harden Runner
uses: step-security/harden-runner@8ca2b8b2ece13480cda6dacd3511b49857a23c09 # v2.5.1
with:
disable-sudo: true
egress-policy: block
allowed-endpoints: >
api.github.com:443
github.com:443
objects.githubusercontent.com:443
proxy.golang.org:443
repo.maven.apache.org:443
storage.googleapis.com:443
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
- name: Set up JDK ${{ matrix.java }}
uses: actions/setup-java@cd89f46ac9d01407894225f350157564c9c7cee2 # v3.12.0
with:
java-version: ${{ matrix.java }}
distribution: temurin
- name: Setup Go
uses: actions/setup-go@93397bea11091df50f3d7e59dc26a7711a8bcfbe # v4.1.0
with:
go-version: '1.21'
- name: Build API with Maven
run: (cd functions-framework-api/ && mvn install)
- name: Build invoker with Maven
run: (cd invoker/ && mvn install)
- name: Build invoker Maven Plugin
run: (cd function-maven-plugin/ && mvn install)
- name: Run HTTP conformance tests
uses: GoogleCloudPlatform/functions-framework-conformance/action@72a4f36b10f1c6435ab1a86a9ea24bda464cc262 # main
with:
functionType: 'http'
useBuildpacks: false
cmd: "'mvn -f invoker/conformance/pom.xml function:run -Drun.functionTarget=com.google.cloud.functions.conformance.HttpConformanceFunction'"
startDelay: 10
- name: Run Typed conformance tests
uses: GoogleCloudPlatform/functions-framework-conformance/action@72a4f36b10f1c6435ab1a86a9ea24bda464cc262 # main
with:
functionType: 'http'
declarativeType: 'typed'
useBuildpacks: false
cmd: "'mvn -f invoker/conformance/pom.xml function:run -Drun.functionTarget=com.google.cloud.functions.conformance.TypedConformanceFunction'"
startDelay: 10
- name: Run background event conformance tests
uses: GoogleCloudPlatform/functions-framework-conformance/action@72a4f36b10f1c6435ab1a86a9ea24bda464cc262 # main
with:
functionType: 'legacyevent'
useBuildpacks: false
validateMapping: true
cmd: "'mvn -f invoker/conformance/pom.xml function:run -Drun.functionTarget=com.google.cloud.functions.conformance.BackgroundEventConformanceFunction'"
startDelay: 10
- name: Run cloudevent conformance tests
uses: GoogleCloudPlatform/functions-framework-conformance/action@72a4f36b10f1c6435ab1a86a9ea24bda464cc262 # main
with:
functionType: 'cloudevent'
useBuildpacks: false
validateMapping: true
cmd: "'mvn -f invoker/conformance/pom.xml function:run -Drun.functionTarget=com.google.cloud.functions.conformance.CloudEventsConformanceFunction'"
startDelay: 10
- name: Run HTTP concurrency conformance tests
uses: GoogleCloudPlatform/functions-framework-conformance/action@72a4f36b10f1c6435ab1a86a9ea24bda464cc262 # main
with:
functionType: 'http'
useBuildpacks: false
validateConcurrency: true
cmd: "'mvn -f invoker/conformance/pom.xml function:run -Drun.functionTarget=com.google.cloud.functions.conformance.ConcurrentHttpConformanceFunction'"
startDelay: 10