{"id":15019301,"url":"https://github.com/grantjenks/django-replay","last_synced_at":"2025-10-24T09:30:29.587Z","repository":{"id":37390922,"uuid":"81888894","full_name":"grantjenks/django-replay","owner":"grantjenks","description":"Django application that records and replays web requests.","archived":false,"fork":false,"pushed_at":"2022-07-10T00:48:49.000Z","size":144,"stargazers_count":4,"open_issues_count":4,"forks_count":2,"subscribers_count":3,"default_branch":"main","last_synced_at":"2024-10-29T22:56:34.748Z","etag":null,"topics":["django","django-admin","record","replay","testing"],"latest_commit_sha":null,"homepage":"https://grantjenks.com/docs/django-replay/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/grantjenks.png","metadata":{"files":{"readme":"README.rst","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-02-14T01:06:20.000Z","updated_at":"2023-07-01T16:44:21.000Z","dependencies_parsed_at":"2022-07-12T12:49:36.066Z","dependency_job_id":null,"html_url":"https://github.com/grantjenks/django-replay","commit_stats":null,"previous_names":[],"tags_count":15,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grantjenks%2Fdjango-replay","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grantjenks%2Fdjango-replay/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grantjenks%2Fdjango-replay/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grantjenks%2Fdjango-replay/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/grantjenks","download_url":"https://codeload.github.com/grantjenks/django-replay/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":237944057,"owners_count":19391588,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["django","django-admin","record","replay","testing"],"created_at":"2024-09-24T19:53:17.777Z","updated_at":"2025-10-24T09:30:29.238Z","avatar_url":"https://github.com/grantjenks.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"Django Replay\n=============\n\n`Django Replay \u003chttp://www.grantjenks.com/docs/django-replay/\u003e`__ is an Apache2\nlicensed Django application that records and replays web requests.\n\n\nFeatures\n--------\n\n- Record requests/responses as easy as \"runserver\"\n- Test scenarios by replaying requests with validators\n- Template requests/responses for dynamic identifiers\n- Tested on Python 3.7, 3.8, 3.9, 3.10\n- Tested on Django 3.2 LTS and Django 4.0\n\n.. image:: https://github.com/grantjenks/django-replay/workflows/integration/badge.svg\n   :target: https://github.com/grantjenks/django-replay/actions?query=workflow%3Aintegration\n\n.. image:: https://github.com/grantjenks/django-replay/workflows/release/badge.svg\n   :target: https://github.com/grantjenks/django-replay/actions?query=workflow%3Arelease\n\n\nQuickstart\n----------\n\nInstalling Django Replay is simple with `pip\n\u003chttp://www.pip-installer.org/\u003e`_::\n\n    $ pip install django-replay\n\nAdd `replay` to the `INSTALLED_APPS` in `settings.py` like:\n\n.. code::\n\n   INSTALLED_APPS += ['replay']\n\nThen migrate the database like:\n\n.. code::\n\n   $ python manage.py migrate\n\nDjango Replay provides two management commands:\n\n1. replayrecord -- like \"runserver\" but request/responses are recorded.\n\n2. replaytest -- runs the scenarios with actions and validators.\n\nDjango Replay also provides three models:\n\n1. Scenario -- ordered list of actions.\n\n2. Action -- recorded request/response template.\n\n3. Validator -- regular expression for response validation.\n\nThese models can be edited in the admin.\n\n\nTutorial\n--------\n\nTo get started, follow the Quickstart and then record some actions:\n\n.. code::\n\n   $ python manage.py replayrecord\n\nNavigate to http://127.0.0.1:8000/ and use the web app as normal. Once the\nactions are recorded run CTRL-C to stop the command.\n\nNow create some scenarios in the admin:\n\n.. code::\n\n   $ python manage.py runserver\n\nTODO: Insert screenshots of creating scenarios.\n\nThe scenarios can be tested manually using:\n\n.. code::\n\n   $ python manage.py replaytest\n\nRemember to clear the content of the actions. Now the tests can be saved in a\nfixture.\n\n.. code::\n\n   $ python manage.py dumpdata --indent 4 replay \u003e replay.json\n\nAnd the scenarios can be integrated with Django's test framework like so:\n\n.. code::\n\n   from django.test import TestCase\n   from replay.utils import test_scenarios\n\n    class ReplayTestCase(TestCase):\n        fixtures = ['path/to/replay.json']\n\n        def test_scenarios(self):\n            test_scenarios()\n\n\nTemplates and Validators\n........................\n\nTODO: Describe templating syntax for requests\n\nTODO: Describe regular expression features for validators\n\n\nReference and Indices\n---------------------\n\n* `Django Replay Documentation`_\n* `Django Replay at PyPI`_\n* `Django Replay at GitHub`_\n* `Django Replay Issue Tracker`_\n\n.. _`Django Replay Documentation`: http://www.grantjenks.com/docs/django-replay/\n.. _`Django Replay at PyPI`: https://pypi.python.org/pypi/django-replay/\n.. _`Django Replay at GitHub`: https://github.com/grantjenks/django-replay\n.. _`Django Replay Issue Tracker`: https://github.com/grantjenks/django-replay/issues\n\n\nDjango Replay License\n---------------------\n\nCopyright 2017-2022 Grant Jenks\n\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\nthis file except in compliance with the License.  You may obtain a copy of the\nLicense at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software distributed\nunder the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR\nCONDITIONS OF ANY KIND, either express or implied.  See the License for the\nspecific language governing permissions and limitations under the License.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgrantjenks%2Fdjango-replay","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgrantjenks%2Fdjango-replay","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgrantjenks%2Fdjango-replay/lists"}