mirror of
https://github.com/beetbox/beets.git
synced 2025-12-31 13:02:47 +01:00
corrected test to account for year and disctotal field now being treated as types.INTEGER
This commit is contained in:
parent
5fc4d7c35e
commit
832c7326af
1 changed files with 6 additions and 1 deletions
|
|
@ -21,6 +21,8 @@ import re
|
|||
import copy
|
||||
import unittest
|
||||
|
||||
from beets.dbcore.types import Integer, PaddedInt
|
||||
|
||||
from test import _common
|
||||
from beets import autotag
|
||||
from beets.autotag import match
|
||||
|
|
@ -91,7 +93,10 @@ class PluralityTest(_common.TestCase):
|
|||
for i in range(5)]
|
||||
likelies, _ = match.current_metadata(items)
|
||||
for f in fields:
|
||||
self.assertEqual(likelies[f], '%s_1' % f)
|
||||
if type(items[0]._fields[f]) in (Integer, PaddedInt):
|
||||
self.assertEqual(likelies[f], 0)
|
||||
else:
|
||||
self.assertEqual(likelies[f], '%s_1' % f)
|
||||
|
||||
|
||||
def _make_item(title, track, artist=u'some artist'):
|
||||
|
|
|
|||
Loading…
Reference in a new issue