Skip to content

Commit 0aaff20

Browse files
fix readme
1 parent e35fc0e commit 0aaff20

File tree

1 file changed

+11
-7
lines changed

1 file changed

+11
-7
lines changed

README.rst

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -24,31 +24,34 @@ Usage
2424
Pytest plugin
2525
*************
2626

27-
The plugin works by using interceptors of different libraries which can be checked by `response.available()` method; these interceptors have to be applied for each pytest run using ``--remote={INTERCEPTOR}``.
27+
The plugin works by using interceptors of different libraries which can be checked by ``response.available()`` method; these interceptors have to be applied for each pytest run using ``--remote={INTERCEPTOR}``.
2828

29-
.. code-block:: console
29+
.. code-block:: bash
3030
$ pytest --remote="urllib_quick|requests_quick|aiohttp_quick"
3131
3232
Handling requests:
3333

3434
- Prevent remote requests:
3535
all requests are allowed by default; one can disable them using `--remote-blocked` flag.
3636

37-
.. code-block:: console
37+
.. code-block:: bash
3838
39-
$ pytest --remote-blocked
39+
$ pytest --remote={INTERCEPTORS} --remote-blocked
4040
4141
- Capture remote requests:
4242
the requests can be captured in a ``json`` file using ``--remote-capture`` arg.
4343

44-
.. code-block:: console
44+
.. code-block:: bash
45+
4546
$ pytest --remote={INTERCEPTORS} --remote-capture
4647
4748
- Mock remote requests:
4849
the requests can be mocked using ``--remote-response`` flag.
49-
NOTE: Due to certain limitations, it is advised to not use this plugin in an offline environment,
50+
51+
NOTE: Due to certain limitations, it is advised to not use this plugin in an offline environment.
52+
53+
.. code-block:: bash
5054
51-
.. code-block:: console
5255
$ pytest --remote={INTERCEPTORS} --remote-response
5356
5457
@@ -60,6 +63,7 @@ The tools implemented in this package can be easily ported to any other applicat
6063
Configuration:
6164

6265
.. code-block:: python
66+
6367
from pytest_response import response
6468
6569
response.setup_database({DUMP FILE})

0 commit comments

Comments
 (0)