Ejemplo n.º 1
0
        public void TestFacade_ReadSource()
        {
            var facade     = new Mp3FormatterFacade(_settings);
            var collection = facade.ReadSourceDirectory();

            Assert.AreEqual(3, collection.Artists.Count(), "should have 3 artists");

            var lookup = collection.Artists.ToDictionary(f => f.Name);

            Assert.IsTrue(lookup.ContainsKey("Ride"));
        }
Ejemplo n.º 2
0
        private void btnGo_Click(object sender, EventArgs e)
        {
            this.groupBox1.Enabled = false;
            this.groupBox2.Enabled = false;

            listResults.Items.Clear();
            var process = new Mp3FormatterFacade(this);

            process.ProcessLog = this;
            process.Process();

            this.groupBox1.Enabled = true;
            this.groupBox2.Enabled = true;
        }
Ejemplo n.º 3
0
        public void TestFacade_WriteAlbumsGavStyleNoFix()
        {
            var settings = FormatterSettingsTests.GetDefaultSettings();

            settings.Format     = FormatStyle.Gav;
            settings.FixTags    = false;
            settings.CopyOrMove = CopyType.Copy;

            var log = new TestLogObject();

            var facade = new Mp3FormatterFacade(settings);

            facade.ProcessLog = log;

            facade.Process();
        }
Ejemplo n.º 4
0
        public void TestFacade_WriteAlbumsPeteStyleWithFix()
        {
            var settings = FormatterSettingsTests.GetDefaultSettings();

            settings.Format     = FormatStyle.Pete;
            settings.FixTags    = true;
            settings.CopyOrMove = CopyType.Copy;

            var log = new TestLogObject();

            var facade = new Mp3FormatterFacade(settings);

            facade.ProcessLog = log;

            facade.Process();

            var mp3 = GetFile("Von Hertzen Brothers - 2013 - Nine Lives\\02-vhb-flowers_and_rust.mp3");

            Assert.AreEqual("Von Hertzen Brothers", mp3.AlbumArtist);
        }