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
Enable Test Proxy logging in Test Framework (#37994)
* Add AMQP constructor to ServiceBusMessage
* Enable logging for test proxy integration
* Clean up
* readme
* add section
* revert default
* Add locking
* Add AspNetCore Info logging
* reduce delay to 20ms
* Put all proxy logging behind flag instead of allowing loglevel config
* Fix wrapping
* Split out CheckForErrors to make it sync
Copy file name to clipboardExpand all lines: sdk/core/Azure.Core.TestFramework/README.md
+5Lines changed: 5 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -380,6 +380,11 @@ The key integration points between the Test Framework and the Test Proxy are:
380
380
- InstrumentClientOptions method of `RecordedTestBase` - calling this on your client options will set the [ClientOptions.Transport property](https://learn.microsoft.com/dotnet/api/azure.core.clientoptions.transport?view=azure-dotnet) to be [ProxyTransport](https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/core/Azure.Core.TestFramework/src/ProxyTransport.cs) to your client options when in `Playback` or `Record` mode. The ProxyTransport will send all requests to the Test Proxy.
381
381
-[TestProxy.cs](https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/core/Azure.Core.TestFramework/src/TestProxy.cs) - This class is responsible for starting and stopping the Test Proxy process, as well as reporting any errors that occur in the Test Proxy process. The Test Proxy process is started automatically when running tests in `Record` or `Playback` mode, and is stopped automatically when the test run is complete. The Test Proxy process is shared between tests and test classes within a process.
382
382
383
+
#### Including Test Proxy Logs
384
+
385
+
In order to enable Test Proxy logging, you can either set the `AZURE_ENABLE_TEST_PROXY_LOGGING`
386
+
environment variable or the `EnableTestProxyLogging`[runsetting](https://github.com/Azure/azure-sdk-for-net/blob/main/eng/nunit.runsettings) parameter to `true`.
387
+
383
388
## Unit tests
384
389
385
390
The Test Framework provides several classes that can help you write unit tests for your client library. Unit tests are helpful for scenarios that would be tricky to test with a recorded test, such as simulating certain error scenarios.
0 commit comments