mirror of
https://github.com/Hopiu/django-rosetta.git
synced 2026-05-04 11:44:42 +00:00
clear the django apps cache key prior to testing
This commit is contained in:
parent
11966cb1de
commit
860e69a686
3 changed files with 27 additions and 25 deletions
2
.gitignore
vendored
2
.gitignore
vendored
|
|
@ -13,4 +13,4 @@ testproject/htmlcov/
|
|||
testproject/rosetta.db
|
||||
testproject/src/
|
||||
testproject/.coverage
|
||||
venv_*
|
||||
.venv_*
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
from django.conf import settings
|
||||
from django.contrib.auth.models import User
|
||||
from django.core.urlresolvers import reverse, resolve
|
||||
from django.core.cache import cache
|
||||
from django.template.defaultfilters import floatformat
|
||||
from django.test import TestCase
|
||||
from django.test.client import Client
|
||||
|
|
@ -287,6 +288,7 @@ class RosettaTestCase(TestCase):
|
|||
|
||||
def test_13_catalog_filters(self):
|
||||
settings.LANGUAGES = (('fr', 'French'), ('xx', 'Dummy Language'),)
|
||||
cache.delete('rosetta_django_paths')
|
||||
self.client.get(reverse('rosetta-pick-file') + '?filter=third-party')
|
||||
r = self.client.get(reverse('rosetta-pick-file'))
|
||||
self.assertTrue(os.path.normpath('rosetta/locale/xx/LC_MESSAGES/django.po') in str(r.content))
|
||||
|
|
|
|||
|
|
@ -1,45 +1,45 @@
|
|||
#!/bin/bash
|
||||
|
||||
if [ ! -d venv_13 ]
|
||||
if [ ! -d .venv_13 ]
|
||||
then
|
||||
virtualenv --no-site-packages --distribute --python=python2 venv_13
|
||||
. venv_13/bin/activate
|
||||
virtualenv --no-site-packages --distribute --python=python2 .venv_13
|
||||
. .venv_13/bin/activate
|
||||
pip install Django==1.3 coverage python-memcached six microsofttranslator
|
||||
deactivate
|
||||
fi
|
||||
if [ ! -d venv_14 ]
|
||||
if [ ! -d .venv_14 ]
|
||||
then
|
||||
virtualenv --no-site-packages --distribute --python=python2 venv_14
|
||||
. venv_14/bin/activate
|
||||
virtualenv --no-site-packages --distribute --python=python2 .venv_14
|
||||
. .venv_14/bin/activate
|
||||
pip install Django==1.4 coverage python-memcached six microsofttranslator
|
||||
deactivate
|
||||
fi
|
||||
if [ ! -d venv_15 ]
|
||||
if [ ! -d .venv_15 ]
|
||||
then
|
||||
virtualenv --no-site-packages --distribute --python=python2 venv_15
|
||||
. venv_15/bin/activate
|
||||
virtualenv --no-site-packages --distribute --python=python2 .venv_15
|
||||
. .venv_15/bin/activate
|
||||
pip install Django==1.5 coverage python-memcached six microsofttranslator
|
||||
deactivate
|
||||
fi
|
||||
if [ ! -d venv_15_p3 ]
|
||||
if [ ! -d .venv_15_p3 ]
|
||||
then
|
||||
virtualenv --no-site-packages --distribute --python=python3 venv_15_p3
|
||||
. venv_15_p3/bin/activate
|
||||
virtualenv --no-site-packages --distribute --python=python3 .venv_15_p3
|
||||
. .venv_15_p3/bin/activate
|
||||
pip install Django==1.5 coverage python3-memcached six microsofttranslator
|
||||
deactivate
|
||||
fi
|
||||
if [ ! -d venv_16 ]
|
||||
if [ ! -d .venv_16 ]
|
||||
then
|
||||
virtualenv --no-site-packages --distribute --python=python2 venv_16
|
||||
. venv_16/bin/activate
|
||||
virtualenv --no-site-packages --distribute --python=python2 .venv_16
|
||||
. .venv_16/bin/activate
|
||||
pip install https://github.com/django/django/archive/1.6b1.zip
|
||||
pip install coverage python-memcached six microsofttranslator
|
||||
deactivate
|
||||
fi
|
||||
if [ ! -d venv_16_p3 ]
|
||||
if [ ! -d .venv_16_p3 ]
|
||||
then
|
||||
virtualenv --no-site-packages --distribute --python=python3 venv_16_p3
|
||||
. venv_16_p3/bin/activate
|
||||
virtualenv --no-site-packages --distribute --python=python3 .venv_16_p3
|
||||
. .venv_16_p3/bin/activate
|
||||
pip install https://github.com/django/django/archive/stable/1.6.x.zip
|
||||
pip install coverage python3-memcached six microsofttranslator
|
||||
deactivate
|
||||
|
|
@ -47,28 +47,28 @@ fi
|
|||
|
||||
|
||||
|
||||
. venv_13/bin/activate
|
||||
. .venv_13/bin/activate
|
||||
cd testproject
|
||||
python manage.py --version
|
||||
python manage.py test rosetta
|
||||
cd ..
|
||||
deactivate
|
||||
|
||||
. venv_14/bin/activate
|
||||
. .venv_14/bin/activate
|
||||
cd testproject
|
||||
python manage.py --version
|
||||
python manage.py test rosetta
|
||||
cd ..
|
||||
deactivate
|
||||
|
||||
. venv_15/bin/activate
|
||||
. .venv_15/bin/activate
|
||||
cd testproject
|
||||
python manage.py --version
|
||||
python manage.py test rosetta
|
||||
cd ..
|
||||
deactivate
|
||||
|
||||
. venv_15_p3/bin/activate
|
||||
. .venv_15_p3/bin/activate
|
||||
cd testproject
|
||||
python manage.py --version
|
||||
python --version
|
||||
|
|
@ -76,14 +76,14 @@ python manage.py test rosetta
|
|||
cd ..
|
||||
deactivate
|
||||
|
||||
. venv_16/bin/activate
|
||||
. .venv_16/bin/activate
|
||||
cd testproject
|
||||
python manage.py --version
|
||||
python manage.py test rosetta
|
||||
cd ..
|
||||
deactivate
|
||||
|
||||
. venv_16_p3/bin/activate
|
||||
. .venv_16_p3/bin/activate
|
||||
cd testproject
|
||||
python manage.py --version
|
||||
python --version
|
||||
|
|
|
|||
Loading…
Reference in a new issue