From 5963755b859cd725f957fa43ec755822908f3054 Mon Sep 17 00:00:00 2001 From: Jannis Leidel Date: Tue, 8 Mar 2011 18:15:34 +0100 Subject: [PATCH] Reverted recent change of the default of COMPRESS_OUTPUT_DIR (back to 'CACHE') to lower the chance for problems during migration from 0.5.X to 0.6.X. --- compressor/settings.py | 2 +- compressor/tests/tests.py | 24 ++++++++++++------------ docs/index.txt | 6 +++--- 3 files changed, 16 insertions(+), 16 deletions(-) diff --git a/compressor/settings.py b/compressor/settings.py index e2db3c1..bec7c47 100644 --- a/compressor/settings.py +++ b/compressor/settings.py @@ -13,7 +13,7 @@ class CompressorSettings(AppSettings): VERBOSE = False # the backend to use when parsing the JavaScript or Stylesheet files PARSER = 'compressor.parser.BeautifulSoupParser' - OUTPUT_DIR = 'cache' + OUTPUT_DIR = 'CACHE' STORAGE = 'compressor.storage.CompressorFileStorage' CSS_COMPRESSOR = "compressor.css.CssCompressor" diff --git a/compressor/tests/tests.py b/compressor/tests/tests.py index c753671..e2c9e43 100644 --- a/compressor/tests/tests.py +++ b/compressor/tests/tests.py @@ -74,7 +74,7 @@ class CompressorTestCase(TestCase): self.assertEqual('f7c661b7a124', self.css_node.hash) def test_css_return_if_on(self): - output = u'' + output = u'' self.assertEqual(output, self.css_node.output().strip()) def test_js_split(self): @@ -106,7 +106,7 @@ class CompressorTestCase(TestCase): settings.COMPRESS_ENABLED = enabled def test_js_return_if_on(self): - output = u'' + output = u'' self.assertEqual(output, self.js_node.output()) def test_custom_output_dir(self): @@ -286,7 +286,7 @@ class TemplatetagTestCase(TestCase): {% endcompress %} """ context = { 'MEDIA_URL': settings.COMPRESS_URL } - out = u'' + out = u'' self.assertEqual(out, render(template, context)) def test_nonascii_css_tag(self): @@ -296,7 +296,7 @@ class TemplatetagTestCase(TestCase): {% endcompress %} """ context = { 'MEDIA_URL': settings.COMPRESS_URL } - out = '' + out = '' self.assertEqual(out, render(template, context)) def test_js_tag(self): @@ -306,7 +306,7 @@ class TemplatetagTestCase(TestCase): {% endcompress %} """ context = { 'MEDIA_URL': settings.COMPRESS_URL } - out = u'' + out = u'' self.assertEqual(out, render(template, context)) def test_nonascii_js_tag(self): @@ -316,7 +316,7 @@ class TemplatetagTestCase(TestCase): {% endcompress %} """ context = { 'MEDIA_URL': settings.COMPRESS_URL } - out = u'' + out = u'' self.assertEqual(out, render(template, context)) def test_nonascii_latin1_js_tag(self): @@ -326,7 +326,7 @@ class TemplatetagTestCase(TestCase): {% endcompress %} """ context = { 'MEDIA_URL': settings.COMPRESS_URL } - out = u'' + out = u'' self.assertEqual(out, render(template, context)) def test_compress_tag_with_illegal_arguments(self): @@ -353,7 +353,7 @@ class StorageTestCase(TestCase): {% endcompress %} """ context = { 'MEDIA_URL': settings.COMPRESS_URL } - out = u'' + out = u'' self.assertEqual(out, render(template, context)) @@ -385,8 +385,8 @@ class OfflineGenerationTestCase(TestCase): count, result = CompressCommand().compress() self.assertEqual(2, count) self.assertEqual(result, [ - u'\n', - u'', + u'\n', + u'', ]) def test_offline_with_context(self): @@ -397,7 +397,7 @@ class OfflineGenerationTestCase(TestCase): count, result = CompressCommand().compress() self.assertEqual(2, count) self.assertEqual(result, [ - u'\n', - u'', + u'\n', + u'', ]) settings.COMPRESS_OFFLINE_CONTEXT = self._old_offline_context diff --git a/docs/index.txt b/docs/index.txt index c925134..048faba 100644 --- a/docs/index.txt +++ b/docs/index.txt @@ -58,7 +58,7 @@ Which would be rendered something like: .. code-block:: django - + or: @@ -75,7 +75,7 @@ Which would be rendered something like: .. code-block:: django - + Linked files must be accesible via COMPRESS_URL_. If DEBUG is ``True``, off-site files will throw exceptions. If DEBUG is ``False`` they will be @@ -185,7 +185,7 @@ compressed static will be written to when using the default COMPRESS_STORAGE_ COMPRESS_OUTPUT_DIR ^^^^^^^^^^^^^^^^^^^ -:Default: ``'cache'`` +:Default: ``'CACHE'`` Controls the directory inside COMPRESS_ROOT_ that compressed files will be written to.