Index: regressiontests/templates/tests.py
===================================================================
--- regressiontests/templates/tests.py	(revision 12122)
+++ regressiontests/templates/tests.py	(working copy)
@@ -965,7 +965,18 @@
             'templatetag10': ('{% templatetag closebrace %}{% templatetag closebrace %}', {}, '}}'),
             'templatetag11': ('{% templatetag opencomment %}', {}, '{#'),
             'templatetag12': ('{% templatetag closecomment %}', {}, '#}'),
-
+            
+            # WHITESPACE TESTING
+            # Tags on their own line should collapse the newline before them
+            'templatetag-whitespace01': ('\n {% templatetag openblock %}\n', {}, '{%\n'),
+            # Tags that start on a newline, but have content thereafter, should not collapse the newline before or after them.
+            'templatetag-whitespace02': ('\n {% templatetag openblock %} String', {}, '\n {% String'),
+            'templatetag-whitespace03': ('\n {% templatetag openblock %} String \n', {}, '\n {% String \n'),
+            'templatetag-whitespace04': ('\n {% templatetag openbrace %}\nString\n{% templatetag closebrace %}\n', {}, '{\nString}\n'),
+            'templatetag-whitespace05': ('\n {% templatetag openbrace %}String{% templatetag closebrace %}\n', {}, '\n {String}\n'),
+            'templatetag-whitespace06': ('\n {% templatetag openbrace %}String{% templatetag closebrace %}', {}, '\n {String}'),
+            'templatetag-whitespace07': (' {% templatetag openbrace %}String{% templatetag closebrace %}', {}, ' {String}'),
+            
             ### WIDTHRATIO TAG ########################################################
             'widthratio01': ('{% widthratio a b 0 %}', {'a':50,'b':100}, '0'),
             'widthratio02': ('{% widthratio a b 100 %}', {'a':0,'b':0}, ''),
@@ -1082,6 +1093,7 @@
             # implementation details (fortunately, the (no)autoescape block
             # tags can be used in those cases)
             'autoescape-filtertag01': ("{{ first }}{% filter safe %}{{ first }} x<y{% endfilter %}", {"first": "<a>"}, template.TemplateSyntaxError),
+            
         }
 
 if __name__ == "__main__":
