mirror of
https://github.com/beetbox/beets.git
synced 2026-03-06 13:12:00 +01:00
fix bug when "applying" sentinel
This commit is contained in:
parent
7503c1174a
commit
584cc74a5c
2 changed files with 7 additions and 1 deletions
|
|
@ -341,7 +341,7 @@ def apply_choices(config):
|
|||
while True:
|
||||
task = yield
|
||||
# Don't do anything if we're skipping the album or we're done.
|
||||
if task.choice_flag == action.SKIP or task.sentinel:
|
||||
if task.sentinel or task.choice_flag == action.SKIP:
|
||||
if config.resume is not False:
|
||||
task.save_progress()
|
||||
continue
|
||||
|
|
|
|||
|
|
@ -99,6 +99,12 @@ class ImportApplyTest(unittest.TestCase, _common.ExtraAsserts):
|
|||
os.path.join(self.libdir, self.lib.path_formats['singleton']+'.mp3')
|
||||
)
|
||||
|
||||
def test_apply_sentinel(self):
|
||||
coro = importer.apply_choices(_common.iconfig(self.lib))
|
||||
coro.next()
|
||||
coro.send(importer.ImportTask.done_sentinel('toppath'))
|
||||
# Just test no exception for now.
|
||||
|
||||
class DuplicateCheckTest(unittest.TestCase):
|
||||
def setUp(self):
|
||||
self.lib = library.Library(':memory:')
|
||||
|
|
|
|||
Loading…
Reference in a new issue