Skip to content

Commit

Permalink
Clean up code-blocks in qt/request_response
Browse files Browse the repository at this point in the history
  • Loading branch information
stevepiercy committed Aug 18, 2018
1 parent 7574fb1 commit 47524e3
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions docs/quick_tutorial/request_response.rst
Original file line number Diff line number Diff line change
Expand Up @@ -39,37 +39,37 @@ Steps

.. code-block:: bash
$ cd ..; cp -r view_classes request_response; cd request_response
$ $VENV/bin/pip install -e .
cd ..; cp -r view_classes request_response; cd request_response
$VENV/bin/pip install -e .
#. Simplify the routes in ``request_response/tutorial/__init__.py``:

.. literalinclude:: request_response/tutorial/__init__.py
:linenos:
:linenos:

#. We only need one view in ``request_response/tutorial/views.py``:

.. literalinclude:: request_response/tutorial/views.py
:linenos:
:linenos:

#. Update the tests in ``request_response/tutorial/tests.py``:

.. literalinclude:: request_response/tutorial/tests.py
:linenos:
:linenos:

#. Now run the tests:

.. code-block:: bash
$ $VENV/bin/py.test tutorial/tests.py -q
.....
5 passed in 0.30 seconds
$VENV/bin/py.test tutorial/tests.py -q
.....
5 passed in 0.30 seconds
#. Run your Pyramid application with:

.. code-block:: bash
$ $VENV/bin/pserve development.ini --reload
$VENV/bin/pserve development.ini --reload
#. Open http://localhost:6543/ in your browser. You will be redirected to
http://localhost:6543/plain.
Expand All @@ -91,7 +91,7 @@ the body of the response:

.. code-block:: text
URL http://localhost:6543/plain?name=alice with name: alice
URL http://localhost:6543/plain?name=alice with name: alice
Finally, we set the response's content type and body, then return the response.

Expand Down

0 comments on commit 47524e3

Please sign in to comment.