public static DiscModel MakeDeleted(this DiscModel disc)
 {
     disc.AddSong(new SongModel {
         DeleteDate = DateTimeOffset.Now
     });
     return(disc);
 }
        public static DiscModel AddSongs(this DiscModel disc, params SongModel[] songs)
        {
            foreach (var song in songs)
            {
                disc.AddSong(song);
            }

            return(disc);
        }
Beispiel #3
0
        public async Task UpdateDisc_TreeTitleWasNotChanged_DoesNotUpdateDiscTreeTitleInStorageRepository()
        {
            // Arrange

            var disc = new DiscModel {
                Id = new ItemId("Disc Id"), Title = "Old Disc Title", TreeTitle = "2021 - Some Disc (CD 1)"
            };

            disc.AddSong(new SongModel());

            var folder = new FolderModel {
                Id = new ItemId("Folder Id"), Name = "Test Folder"
            };

            folder.AddDisc(disc);

            var mocker = new AutoMocker();
            var target = mocker.CreateInstance <DiscsService>();
 public static DiscModel MakeActive(this DiscModel disc)
 {
     disc.AddSong(new SongModel());
     return(disc);
 }
Beispiel #5
0
 public static SongModel AddToDisc(this SongModel song, DiscModel disc)
 {
     disc.AddSong(song);
     return(song);
 }