mirror of
https://github.com/lidarr/Lidarr
synced 2025-01-03 05:25:10 +00:00
Add test for Scene name not being set during import
(cherry picked from commit 044342f6779740a630eb56eba7587fb8da5d77f6) Closes #1994
This commit is contained in:
parent
fc6175e597
commit
0fb07a54d6
1 changed files with 13 additions and 0 deletions
|
@ -218,5 +218,18 @@ public void should_delete_existing_trackfiles_with_the_same_path()
|
||||||
Mocker.GetMock<IMediaFileService>()
|
Mocker.GetMock<IMediaFileService>()
|
||||||
.Verify(v => v.Delete(It.IsAny<TrackFile>(), DeleteMediaFileReason.ManualOverride), Times.Once());
|
.Verify(v => v.Delete(It.IsAny<TrackFile>(), DeleteMediaFileReason.ManualOverride), Times.Once());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[Test]
|
||||||
|
public void should_include_scene_name_with_new_downloads()
|
||||||
|
{
|
||||||
|
var firstDecision = _approvedDecisions.First();
|
||||||
|
firstDecision.Item.SceneName = "Artist.Name.Album.Name.TrackNum.Track.Title.MP3256";
|
||||||
|
|
||||||
|
Subject.Import(new List<ImportDecision<LocalTrack>> { _approvedDecisions.First() }, true);
|
||||||
|
|
||||||
|
Mocker.GetMock<IUpgradeMediaFiles>()
|
||||||
|
.Verify(v => v.UpgradeTrackFile(It.Is<TrackFile>(e => e.SceneName == firstDecision.Item.SceneName), _approvedDecisions.First().Item, false),
|
||||||
|
Times.Once());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue