Fix an import issue after the last cleanup.

- Fix an issue with an import that changed in the last cleanup effort (as a side note, the plugins manager test is a good one to use to check for import regressions).
- Clean up some test comments.
This commit is contained in:
Raoul Snyman 2013-03-11 23:10:29 +02:00
parent 9383f2a4af
commit cdbd34460a
3 changed files with 9 additions and 7 deletions

View File

@ -386,6 +386,8 @@ def clean_song(manager, song):
``song``
The song object.
"""
from xml import SongXML
if isinstance(song.title, buffer):
song.title = unicode(song.title)
if isinstance(song.alternate_title, buffer):

View File

@ -42,7 +42,7 @@ class TestPluginManager(TestCase):
def find_plugins_test(self):
"""
Test the find_plugins() method to ensure it imports the correct plugins.
Test the find_plugins() method to ensure it imports the correct plugins
"""
# GIVEN: A plugin manager
plugin_manager = PluginManager()

View File

@ -39,7 +39,7 @@ class TestAuthorsForm(TestCase):
def get_first_name_property_test(self):
"""
Test that getting the first name property on the AuthorForm works correctly.
Test that getting the first name property on the AuthorForm works correctly
"""
# GIVEN: A first name to set
first_name = u'John'
@ -52,7 +52,7 @@ class TestAuthorsForm(TestCase):
def set_first_name_property_test(self):
"""
Test that setting the first name property on the AuthorForm works correctly.
Test that setting the first name property on the AuthorForm works correctly
"""
# GIVEN: A first name to set
first_name = u'James'
@ -65,7 +65,7 @@ class TestAuthorsForm(TestCase):
def get_last_name_property_test(self):
"""
Test that getting the last name property on the AuthorForm works correctly.
Test that getting the last name property on the AuthorForm works correctly
"""
# GIVEN: A last name to set
last_name = u'Smith'
@ -78,7 +78,7 @@ class TestAuthorsForm(TestCase):
def set_last_name_property_test(self):
"""
Test that setting the last name property on the AuthorForm works correctly.
Test that setting the last name property on the AuthorForm works correctly
"""
# GIVEN: A last name to set
last_name = u'Potter'
@ -91,7 +91,7 @@ class TestAuthorsForm(TestCase):
def get_display_name_property_test(self):
"""
Test that getting the display name property on the AuthorForm works correctly.
Test that getting the display name property on the AuthorForm works correctly
"""
# GIVEN: A display name to set
display_name = u'John'
@ -104,7 +104,7 @@ class TestAuthorsForm(TestCase):
def set_display_name_property_test(self):
"""
Test that setting the display name property on the AuthorForm works correctly.
Test that setting the display name property on the AuthorForm works correctly
"""
# GIVEN: A display name to set
display_name = u'John'