You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/azure-functions/durable/durable-functions-unit-testing-dotnet-isolated.md
+9-7Lines changed: 9 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -12,8 +12,9 @@ ms.author: azfuncdf
12
12
Unit testing is an important part of modern software development practices. Unit tests verify business logic behavior and protect from introducing unnoticed breaking changes in the future. Durable Functions can easily grow in complexity so introducing unit tests helps avoid breaking changes. The following sections explain how to unit test the three function types - Orchestration client, orchestrator, and activity functions.
13
13
14
14
> [!NOTE]
15
-
> This article provides guidance for unit testing for Durable Functions apps written in C# for the .NET out-of-process worker. For more information about Durable Functions in the .NET isolated worker, see the [Durable Functions in the .NET isolated worker](durable-functions-dotnet-isolated-overview.md) article.
16
-
> The complete sample code for this unit testing guide can be found in [the sample code repository](https://github.com/Azure/azure-functions-durable-extension/tree/dev/samples/isolated-unit-tests).
15
+
> This article provides guidance for unit testing for Durable Functions apps written in C# for the .NET isolated worker. For more information about Durable Functions in the .NET isolated worker, see the [Durable Functions in the .NET isolated worker](durable-functions-dotnet-isolated-overview.md) article.
16
+
> **The complete sample code for this unit testing guide can be found in [the sample code repository](https://github.com/Azure/azure-functions-durable-extension/tree/dev/samples/isolated-unit-tests)**.
17
+
> The unit testing guide for Durable Functions written in C# in-process can be found [here](durable-functions-unit-testing.md).
17
18
18
19
## Prerequisites
19
20
@@ -33,7 +34,7 @@ Mocking is supported via the following interfaces and classes:
33
34
*`FunctionContext` - For function execution context
34
35
*`HttpRequestData` and `HttpResponseData` - For HTTP trigger functions
35
36
36
-
These classes can be used with the various trigger and bindings supported by Durable Functions. While it is executing your Azure Functions, the functions runtime runs your function code with concrete implementations of these classes. For unit testing, you can pass in a mocked version of these classes to test your business logic.
37
+
These classes can be used with the various trigger and bindings supported by Durable Functions. While it's executing your Azure Functions, the functions runtime runs your function code with concrete implementations of these classes. For unit testing, you can pass in a mocked version of these classes to test your business logic.
37
38
38
39
## Unit testing trigger functions
39
40
@@ -65,7 +66,7 @@ var durableClientMock = new Mock<DurableTaskClient>("testClient");
0 commit comments