Skip to content

Commit b6d16f6

Browse files
author
Victoria Hall
committed
run emulators for blob tests
1 parent e87a31a commit b6d16f6

File tree

2 files changed

+96
-0
lines changed

2 files changed

+96
-0
lines changed

eng/ci/emulator-tests.yml

+43
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
trigger: none # ensure this is not ran as a CI build
2+
3+
pr:
4+
branches:
5+
include:
6+
- dev
7+
- release/*
8+
9+
schedules:
10+
- cron: "0 8 * * 1,2,3,4,5"
11+
displayName: Monday to Friday 3 AM CST build
12+
branches:
13+
include:
14+
- dev
15+
always: true
16+
17+
resources:
18+
repositories:
19+
- repository: 1es
20+
type: git
21+
name: 1ESPipelineTemplates/1ESPipelineTemplates
22+
ref: refs/tags/release
23+
- repository: eng
24+
type: git
25+
name: engineering
26+
ref: refs/tags/release
27+
28+
variables:
29+
- template: /ci/variables/build.yml@eng
30+
- template: /ci/variables/cfs.yml@eng
31+
32+
extends:
33+
template: v1/1ES.Unofficial.PipelineTemplate.yml@1es
34+
parameters:
35+
pool:
36+
name: 1es-pool-azfunc
37+
image: 1es-windows-2022
38+
os: windows
39+
40+
stages:
41+
- stage: RunEmulatorTests
42+
jobs:
43+
- template: /eng/templates/jobs/ci-emulator-tests.yml@self
+53
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
jobs:
2+
- job: "TestPython"
3+
displayName: "Run Python Emulator Tests"
4+
5+
pool:
6+
name: 1es-pool-azfunc
7+
image: 1es-ubuntu-22.04
8+
os: linux
9+
10+
strategy:
11+
matrix:
12+
Python37:
13+
PYTHON_VERSION: '3.7'
14+
Python38:
15+
PYTHON_VERSION: '3.8'
16+
Python39:
17+
PYTHON_VERSION: '3.9'
18+
Python310:
19+
PYTHON_VERSION: '3.10'
20+
Python311:
21+
PYTHON_VERSION: '3.11'
22+
steps:
23+
- task: UsePythonVersion@0
24+
inputs:
25+
versionSpec: $(PYTHON_VERSION)
26+
- task: UseDotNet@2
27+
displayName: 'Install .NET 8'
28+
inputs:
29+
version: 8.0.x
30+
- bash: |
31+
python -m pip install --upgrade pip
32+
python -m pip install -U azure-functions --pre
33+
python -m pip install -U -e .[dev]
34+
35+
if [[ $(PYTHON_VERSION) != "3.7" ]]; then
36+
python -m pip install --pre -U -e .[test-http-v2]
37+
fi
38+
if [[ $(PYTHON_VERSION) != "3.7" && $(PYTHON_VERSION) != "3.8" ]]; then
39+
python -m pip install --pre -U -e .[test-deferred-bindings]
40+
fi
41+
42+
python setup.py build
43+
displayName: 'Install dependencies and the worker'
44+
- bash: |
45+
sudo npm install -g azurite
46+
sudo mkdir azurite
47+
sudo azurite --silent --location azurite --debug azurite\debug.log &
48+
displayName: 'Install and Run Azurite'
49+
- bash: |
50+
python -m pytest -q -n auto --dist loadfile --reruns 4 tests/endtoend/test_blob_functions.py
51+
env:
52+
AzureWebJobsStorage: "UseDevelopmentStorage=true"
53+
displayName: "Running $(PYTHON_VERSION) Python E2E Tests"

0 commit comments

Comments
 (0)