using System.Collections.Generic; using System.IO; using MbUnit.Framework; using NzbDrone.Core.Repository; namespace NzbDrone.Core.Test { [TestFixture] public class QualityProfileTest { /// /// Test_s the storage. /// /// /// [Test] public void Test_Storage() { //Arrange var repo = MockLib.EmptyRepository; var testProfile = new QualityProfile { Cutoff = Quality.SDTV, Allowed = new List() { Quality.HDTV, Quality.DVD }, }; //Act var id = (int)repo.Add(testProfile); var fetch = repo.Single(c => c.Id == id); //Assert Assert.AreEqual(id, fetch.Id); Assert.AreEqual(testProfile.Cutoff, fetch.Cutoff); Assert.AreEqual(testProfile.Allowed, fetch.Allowed); } } }