Commit c9240c02 by Timothée Peignier

add empty dummy tests

parent 0f3aadc5
#!/usr/bin/env python
import os
import sys
from django.conf import settings
TEST_DIR = os.path.dirname(os.path.abspath(__file__))
if not settings.configured:
settings.configure(
COMPRESS_CACHE_BACKEND = 'dummy://',
DATABASE_ENGINE='sqlite3',
INSTALLED_APPS=[
'compress',
'tests',
],
MEDIA_URL = '/media/',
MEDIA_ROOT = os.path.join(TEST_DIR, 'media'),
STATIC_URL = '/static/',
STATIC_ROOT = os.path.join(TEST_DIR, 'static'),
TEMPLATE_DIRS = (
os.path.join(TEST_DIR, 'templates'),
),
TEST_DIR = TEST_DIR,
)
from django.test.simple import run_tests
def runtests(*test_args):
if not test_args:
test_args = ['tests']
sys.path.insert(0, os.path.join(TEST_DIR, ".."))
failures = run_tests(test_args, verbosity=1, interactive=True)
sys.exit(failures)
if __name__ == '__main__':
runtests(*sys.argv[1:])
function() {
alert('this is a test');
}
\ No newline at end of file
import os
from django.test import TestCase
from compress.conf import settings
from compress.packager import Packager
class PackagerTest(TestCase):
def setUp(self):
self.old_compress_url = settings.COMPRESS_URL
settings.COMPRESS_URL = 'http://localhost/static/'
def test_individual_url(self):
"""Check that individual URL is correctly generated"""
packager = Packager()
filename = os.path.join(settings.COMPRESS_ROOT, u'js/application.js')
individual_url = packager.individual_url(filename)
self.assertEqual(individual_url,
"http://localhost/static/js/application.js")
def tearDown(self):
settings.COMPRESS_URL = self.old_compress_url
class VersioningTest(TestCase):
pass
class CompressorTest(TestCase):
pass
class CompilerTest(TestCase):
pass
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment