-
Notifications
You must be signed in to change notification settings - Fork 415
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add unit tests for azure_functions integration
- Loading branch information
1 parent
856e062
commit cdecdaa
Showing
18 changed files
with
371 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# | ||
# This file is autogenerated by pip-compile with Python 3.8 | ||
# by the following command: | ||
# | ||
# pip-compile --allow-unsafe --no-annotate .riot/requirements/1337ee3.in | ||
# | ||
attrs==24.2.0 | ||
azure-functions==1.21.3 | ||
certifi==2024.8.30 | ||
charset-normalizer==3.4.0 | ||
coverage[toml]==7.6.1 | ||
exceptiongroup==1.2.2 | ||
hypothesis==6.45.0 | ||
idna==3.10 | ||
iniconfig==2.0.0 | ||
mock==5.1.0 | ||
opentracing==2.4.0 | ||
packaging==24.2 | ||
pluggy==1.5.0 | ||
pytest==8.3.3 | ||
pytest-cov==5.0.0 | ||
pytest-mock==3.14.0 | ||
requests==2.32.3 | ||
sortedcontainers==2.4.0 | ||
tomli==2.1.0 | ||
urllib3==2.2.3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# | ||
# This file is autogenerated by pip-compile with Python 3.11 | ||
# by the following command: | ||
# | ||
# pip-compile --allow-unsafe --no-annotate .riot/requirements/14b54db.in | ||
# | ||
attrs==24.2.0 | ||
azure-functions==1.21.3 | ||
certifi==2024.8.30 | ||
charset-normalizer==3.4.0 | ||
coverage[toml]==7.6.8 | ||
hypothesis==6.45.0 | ||
idna==3.10 | ||
iniconfig==2.0.0 | ||
mock==5.1.0 | ||
opentracing==2.4.0 | ||
packaging==24.2 | ||
pluggy==1.5.0 | ||
pytest==8.3.3 | ||
pytest-cov==6.0.0 | ||
pytest-mock==3.14.0 | ||
requests==2.32.3 | ||
sortedcontainers==2.4.0 | ||
urllib3==2.2.3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# | ||
# This file is autogenerated by pip-compile with Python 3.10 | ||
# by the following command: | ||
# | ||
# pip-compile --allow-unsafe --no-annotate .riot/requirements/1e62aea.in | ||
# | ||
attrs==24.2.0 | ||
azure-functions==1.21.3 | ||
certifi==2024.8.30 | ||
charset-normalizer==3.4.0 | ||
coverage[toml]==7.6.8 | ||
exceptiongroup==1.2.2 | ||
hypothesis==6.45.0 | ||
idna==3.10 | ||
iniconfig==2.0.0 | ||
mock==5.1.0 | ||
opentracing==2.4.0 | ||
packaging==24.2 | ||
pluggy==1.5.0 | ||
pytest==8.3.3 | ||
pytest-cov==6.0.0 | ||
pytest-mock==3.14.0 | ||
requests==2.32.3 | ||
sortedcontainers==2.4.0 | ||
tomli==2.1.0 | ||
urllib3==2.2.3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
# | ||
# This file is autogenerated by pip-compile with Python 3.7 | ||
# by the following command: | ||
# | ||
# pip-compile --allow-unsafe --config=pyproject.toml --no-annotate --resolver=backtracking .riot/requirements/73109d5.in | ||
# | ||
attrs==24.2.0 | ||
azure-functions==1.21.3 | ||
certifi==2024.8.30 | ||
charset-normalizer==3.4.0 | ||
coverage[toml]==7.2.7 | ||
exceptiongroup==1.2.2 | ||
hypothesis==6.45.0 | ||
idna==3.10 | ||
importlib-metadata==6.7.0 | ||
iniconfig==2.0.0 | ||
mock==5.1.0 | ||
opentracing==2.4.0 | ||
packaging==24.0 | ||
pluggy==1.2.0 | ||
pytest==7.4.4 | ||
pytest-cov==4.1.0 | ||
pytest-mock==3.11.1 | ||
requests==2.31.0 | ||
sortedcontainers==2.4.0 | ||
tomli==2.0.1 | ||
typing-extensions==4.7.1 | ||
urllib3==2.0.7 | ||
zipp==3.15.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# | ||
# This file is autogenerated by pip-compile with Python 3.9 | ||
# by the following command: | ||
# | ||
# pip-compile --allow-unsafe --no-annotate .riot/requirements/c2420c2.in | ||
# | ||
attrs==24.2.0 | ||
azure-functions==1.21.3 | ||
certifi==2024.8.30 | ||
charset-normalizer==3.4.0 | ||
coverage[toml]==7.6.8 | ||
exceptiongroup==1.2.2 | ||
hypothesis==6.45.0 | ||
idna==3.10 | ||
iniconfig==2.0.0 | ||
mock==5.1.0 | ||
opentracing==2.4.0 | ||
packaging==24.2 | ||
pluggy==1.5.0 | ||
pytest==8.3.3 | ||
pytest-cov==6.0.0 | ||
pytest-mock==3.14.0 | ||
requests==2.32.3 | ||
sortedcontainers==2.4.0 | ||
tomli==2.1.0 | ||
urllib3==2.2.3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
14 changes: 14 additions & 0 deletions
14
tests/contrib/azure_functions/azure_function_app/function_app.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
from ddtrace import patch | ||
|
||
|
||
patch(azure_functions=True) | ||
|
||
import azure.functions as func # noqa: E402 | ||
|
||
|
||
app = func.FunctionApp() | ||
|
||
|
||
@app.route(route="httptest", auth_level=func.AuthLevel.ANONYMOUS) | ||
def http_test(req: func.HttpRequest) -> func.HttpResponse: | ||
return func.HttpResponse("Hello Datadog!") |
15 changes: 15 additions & 0 deletions
15
tests/contrib/azure_functions/azure_function_app/host.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{ | ||
"version": "2.0", | ||
"logging": { | ||
"applicationInsights": { | ||
"samplingSettings": { | ||
"isEnabled": true, | ||
"excludedTypes": "Request" | ||
} | ||
} | ||
}, | ||
"extensionBundle": { | ||
"id": "Microsoft.Azure.Functions.ExtensionBundle", | ||
"version": "[4.*, 5.0.0)" | ||
} | ||
} |
8 changes: 8 additions & 0 deletions
8
tests/contrib/azure_functions/azure_function_app/local.settings.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
{ | ||
"IsEncrypted": false, | ||
"Values": { | ||
"FUNCTIONS_WORKER_RUNTIME": "python", | ||
"AzureWebJobsFeatureFlags": "EnableWorkerIndexing", | ||
"AzureWebJobsStorage": "" | ||
} | ||
} |
Oops, something went wrong.