I have added the django-countries app to my project and am attempting to run the tests, but they fail when executing the syncdb
command from the utils/tests.py file because the tables it's trying to create are already present. My project uses django-south to handle db migrations. Here is a stack dump of one of the test failures.
#!python
======================================================================
ERROR: test_unicode (django_countries.tests.TestCountryField)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/django_countries-1.0.5-py2.6.egg/django_countries/utils/tests.py", line 22, in setUp
call_command('syncdb', verbosity=0, interactive=False)
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/Django-1.2.4-py2.6.egg/django/core/management/__init__.py", line 166, in call_command
return klass.execute(*args, **defaults)
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/Django-1.2.4-py2.6.egg/django/core/management/base.py", line 220, in execute
output = self.handle(*args, **options)
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/Django-1.2.4-py2.6.egg/django/core/management/base.py", line 351, in handle
return self.handle_noargs(**options)
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/South-0.7.3-py2.6.egg/south/management/commands/syncdb.py", line 99, in handle_noargs
management.call_command('migrate', **options)
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/Django-1.2.4-py2.6.egg/django/core/management/__init__.py", line 166, in call_command
return klass.execute(*args, **defaults)
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/Django-1.2.4-py2.6.egg/django/core/management/base.py", line 220, in execute
output = self.handle(*args, **options)
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/South-0.7.3-py2.6.egg/south/management/commands/migrate.py", line 105, in handle
ignore_ghosts = ignore_ghosts,
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/South-0.7.3-py2.6.egg/south/migration/__init__.py", line 191, in migrate_app
success = migrator.migrate_many(target, workplan, database)
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/South-0.7.3-py2.6.egg/south/migration/migrators.py", line 221, in migrate_many
result = migrator.__class__.migrate_many(migrator, target, migrations, database)
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/South-0.7.3-py2.6.egg/south/migration/migrators.py", line 292, in migrate_many
result = self.migrate(migration, database)
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/South-0.7.3-py2.6.egg/south/migration/migrators.py", line 125, in migrate
result = self.run(migration)
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/South-0.7.3-py2.6.egg/south/migration/migrators.py", line 99, in run
return self.run_migration(migration)
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/South-0.7.3-py2.6.egg/south/migration/migrators.py", line 81, in run_migration
migration_function()
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/South-0.7.3-py2.6.egg/south/migration/migrators.py", line 57, in <lambda>
return (lambda: direction(orm))
File "/home/vagrant/sg/simplegeo.com/balboa/apps/website/migrations/0001_initial.py", line 17, in forwards
('public', self.gf('django.db.models.fields.BooleanField')(default=False)),
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/South-0.7.3-py2.6.egg/south/db/generic.py", line 226, in create_table
', '.join([col for col in columns if col]),
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/South-0.7.3-py2.6.egg/south/db/generic.py", line 150, in execute
cursor.execute(sql, params)
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/Django-1.2.4-py2.6.egg/django/db/backends/mysql/base.py", line 86, in execute
return self.cursor.execute(query, args)
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/MySQL_python-1.2.3-py2.6-linux-i686.egg/MySQLdb/cursors.py", line 174, in execute
self.errorhandler(self, exc, value)
File "/home/vagrant/sg/simplegeo.com/lib/python2.6/site-packages/MySQL_python-1.2.3-py2.6-linux-i686.egg/MySQLdb/connections.py", line 36, in defaulterrorhandler
raise errorclass, errorvalue
OperationalError: (1050, "Table 'website_license' already exists")