https://github.com/null-none/django-asserts
Test Django HTML with Context Managers
https://github.com/null-none/django-asserts
django html python tests unittest
Last synced: 26 days ago
JSON representation
Test Django HTML with Context Managers
- Host: GitHub
- URL: https://github.com/null-none/django-asserts
- Owner: null-none
- License: mit
- Created: 2024-07-20T17:46:17.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2024-10-18T17:18:47.000Z (over 1 year ago)
- Last Synced: 2025-09-27T12:36:25.095Z (9 months ago)
- Topics: django, html, python, tests, unittest
- Language: Python
- Homepage:
- Size: 9.77 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# django-asserts
## Overview
Test HTML with Context Managers
### Example
```python
from django.test import TestCase
from django_asserts import AssertHTMLMixin
class MyTest(TestCase, AssertHTMLMixin):
def test_view(self):
self.assertHTML(response, "#id-element"):
```