Skip to content

Commit f4ab768

Browse files
authored
Add test proxy setup instructions to dev_setup.md (#27081)
1 parent 9357d9d commit f4ab768

File tree

2 files changed

+15
-7
lines changed

2 files changed

+15
-7
lines changed

doc/dev/dev_setup.md

+14-6
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
# Getting the tests to run
1+
# Run SDK tests
22

3-
This section describes how to create a dev environment, in order to run the SDK tests,
3+
This document describes how to create a dev environment in order to run SDK tests
44
or execute the various commands available in the toolbox.
55

6-
## Setting up a virtual environment
6+
## Set up a virtual environment
77

88
1. If you don't already have it, install Python:
99

@@ -33,7 +33,7 @@ or execute the various commands available in the toolbox.
3333
3434
4. Setup your development environment
3535
36-
Install the development requirements for a specific library (located in the `dev_requirements.txt` file at the root of the library), [Tox][tox], [Tox monorepo][tox_monorepo] and an editable install of your library:
36+
Install the development requirements for a specific library (located in the `dev_requirements.txt` file at the root of the library), [Tox][tox], [Tox monorepo][tox_monorepo] and an editable install of your library. For example, to install requirements for `azure-ai-formrecognizer`:
3737
```
3838
azure-sdk-for-python> cd sdk/formrecognizer/azure-ai-formrecognizer
3939
azure-sdk-for-python/sdk/formrecognizer/azure-ai-formrecognizer> pip install -r dev_requirements.txt
@@ -46,10 +46,18 @@ or execute the various commands available in the toolbox.
4646
The recommended place to store your .env file is one directory higher than the `azure-sdk-for-python` location.
4747
This ensures the secrets will be loaded by the interpreter and most importantly not be committed to Git history.
4848
49+
## Set up the SDK's test-running tool
50+
51+
SDK tests use an in-house tool called the test proxy, which runs in a container and enables recording and playing back HTTP interactions.
52+
53+
Follow the instructions in the [Perform one-time test proxy setup][proxy_setup] section of [tests.md][tests] to set up the test proxy on your machine.
54+
4955
5056
<!-- LINKS -->
5157
[python_website]: https://www.python.org/downloads/
5258
[python_39]: https://www.microsoft.com/p/python-39/9p7qfqmjrfp7
53-
[virtual_environment]: https://docs.python.org/3/tutorial/venv.html
59+
[proxy_setup]: https://github.com/Azure/azure-sdk-for-python/blob/main/doc/dev/tests.md#perform-one-time-test-proxy-setup
60+
[tests]: https://github.com/Azure/azure-sdk-for-python/blob/main/doc/dev/tests.md
5461
[tox]: https://tox.readthedocs.io/en/latest/
55-
[tox_monorepo]: https://pypi.org/project/tox-monorepo/
62+
[tox_monorepo]: https://pypi.org/project/tox-monorepo/
63+
[virtual_environment]: https://docs.python.org/3/tutorial/venv.html

doc/dev/tests.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -652,7 +652,7 @@ Tests that use the Shared Access Signature (SAS) to authenticate a client should
652652

653653
[packaging]: https://github.com/Azure/azure-sdk-for-python/blob/main/doc/dev/packaging.md
654654
[podman]: https://podman.io/
655-
[proxy_cert_docs]: https://github.com/Azure/azure-sdk-tools/blob/main/tools/test-proxy/documentation/trusting-cert-per-language.md
655+
[proxy_cert_docs]: https://github.com/Azure/azure-sdk-tools/blob/main/tools/test-proxy/documentation/test-proxy/trusting-cert-per-language.md
656656
[proxy_general_docs]: https://github.com/Azure/azure-sdk-tools/blob/main/tools/test-proxy/README.md
657657
[proxy_migration_guide]: https://github.com/Azure/azure-sdk-for-python/blob/main/doc/dev/test_proxy_migration_guide.md
658658
[py_sanitizers]: https://github.com/Azure/azure-sdk-for-python/blob/main/tools/azure-sdk-tools/devtools_testutils/sanitizers.py

0 commit comments

Comments
 (0)