Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Add section on override_settings.

  • Loading branch information...
commit 0d156a16e56151e7da2a9557d62fc618d672f20a 1 parent 1d5e4a5
@carljm authored
View
4 doctests/10_intro.md
@@ -43,8 +43,8 @@
<!SLIDE incremental>
-# Now your examples are tested! #
+# Your examples are tested! #
-* Don't abuse this.
+* Please don't abuse this.
* Keep them documentation first.
View
5 settings/10_intro.md
@@ -0,0 +1,5 @@
+<!SLIDE>
+
+# You have a setting. #
+
+* `ALLOW_COMMENTS`, for example.
View
10 settings/20_bad.md
@@ -0,0 +1,10 @@
+<!SLIDE antipattern>
+
+ @@@ python
+ def test_comments_allowed(self):
+ old_allow = settings.ALLOW_COMMENTS
+ settings.ALLOW_COMMENTS = True
+ try:
+ # ...
+ finally:
+ settings.ALLOW_COMMENTS = old_allow
View
6 settings/30_good.md
@@ -0,0 +1,6 @@
+<!SLIDE>
+
+ @@@ python
+ @override_settings(ALLOW_COMMENTS=True)
+ def test_comments_allowed(self):
+ # ...
View
2  showoff.json
@@ -3,7 +3,7 @@
"sections": [
{"section":"title"},
{"section":"whichtests"},
- {"section": "levels"},
+ {"section":"levels"},
{"section":"models"},
{"section":"views"},
{"section":"doctests"},
Please sign in to comment.
Something went wrong with that request. Please try again.