Skip to content

Commit 355770c

Browse files
committed
PR feedback
1 parent 4e45d7b commit 355770c

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

articles/azure-functions/durable/durable-functions-unit-testing-python.md

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@ Unit testing Durable Functions is essential to ensure the correctness of individ
55

66
This guide provides an overview of unit testing Durable Functions in Python, covering the key components: starter functions, orchestrators, activity functions, and entity functions. It includes best practices and sample test cases to help you write robust and maintainable tests for your Durable Functions.
77

8+
[!NOTE]
9+
This guide applies only to Durable Functions apps written in the [Python v2 programming model](../functions-reference-python.md).
10+
811
## Prerequisites
912
The examples in this article require knowledge of the following concepts and frameworks:
1013

@@ -14,7 +17,7 @@ The examples in this article require knowledge of the following concepts and fra
1417
* [unittest.mock](https://docs.python.org/3/library/unittest.mock.html)
1518

1619
## Setting Up the Test Environment
17-
To test Durable Functions, it's crucial to set up a proper test environment. This includes creating a test directory and installing unittest into your Python environment. For more info, see the Azure Functions Python unit testing overview [here](https://learn.microsoft.com/en-us/azure/azure-functions/functions-reference-python?tabs=get-started%2Casgi%2Capplication-level&pivots=python-mode-decorators#unit-testing).
20+
To test Durable Functions, it's crucial to set up a proper test environment. This includes creating a test directory and installing unittest into your Python environment. For more info, see the [Azure Functions Python unit testing overview](../functions-reference-python.md#unit-testing).
1821

1922
## Testing Durable Clients
2023
Durable Client functions initiate orchestrations and external events. To test a client function:
@@ -145,7 +148,7 @@ class TestEntityFunction(unittest.TestCase):
145148
```
146149

147150
## Testing Activity Functions
148-
Activity functions require no Durable-specific modifications to be tested. The guidance found in the Azure Functions Python unit testing overview [here](https://learn.microsoft.com/en-us/azure/azure-functions/functions-reference-python?tabs=get-started%2Casgi%2Capplication-level&pivots=python-mode-decorators#unit-testing) is sufficient for testing these functions.
151+
Activity functions require no Durable-specific modifications to be tested. The guidance found in the [Azure Functions Python unit testing overview](../functions-reference-python.md#unit-testing) is sufficient for testing these functions.
149152

150153
## Summary
151154
Testing Durable Functions effectively requires simulating their unique runtime behaviors while keeping tests isolated and deterministic. Here are some best practices to keep in mind:
@@ -165,6 +168,6 @@ By applying these practices, you can build a comprehensive test suite for your D
165168

166169
For deeper insights into Durable Functions in Python, explore these resources:
167170

168-
- [Durable Functions GitHub Samples](https://github.com/Azure/azure-functions-durable-python)
169-
- [Azure Functions Python Developer Guide](https://learn.microsoft.com/azure/azure-functions/functions-reference-python)
170-
- [Azure Durable Functions Documentation](https://learn.microsoft.com/azure/azure-functions/durable/durable-functions-overview)
171+
- [Improve throughput performance of Python apps in Azure Functions](../python-scale-performance-reference.md)
172+
- [Azure Functions Python Developer Guide](../functions-reference-python.md)
173+
- [Durable Functions best practices and diagnostic tools](./durable-functions-best-practice-reference.md)

0 commit comments

Comments
 (0)