Ejemplo n.º 1
0
        private void MigratePsalms()
        {
            Console.WriteLine("MigratePsalms()");
            string folder = Path.Combine(FOLDER_PATH, @"Books\Psalter");

            var service = new PsalterService(_unitOfWork);

            var manager = new PsalmsMigrationManager(service, new TypiconSerializer());

            manager.MigratePsalms(new PsalterRuReader(folder, DEFAULT_LANGUAGE));
            Commit();
            manager.MigratePsalms(new PsalterCsReader(folder, "cs-cs"));
            Commit();
        }
Ejemplo n.º 2
0
        private void MigratePsalms()
        {
            Console.WriteLine("MigratePsalms()");
            string folder = Path.Combine(Properties.Settings.Default.FolderPath, @"Books\Psalter");

            var service = new PsalterService(_unitOfWork);

            var manager = new PsalmsMigrationManager(service);

            manager.MigratePsalms(new PsalterRuReader(folder, "cs-ru"));
            Commit();
            manager.MigratePsalms(new PsalterCsReader(folder, "cs-cs"));
            Commit();
        }
        public void PsalmsMigrationManager_CsTest()
        {
            var uof     = new EFUnitOfWork();
            var service = new FakePsalterService(uof);

            var manager = new PsalmsMigrationManager(service);

            string folderPath = Path.Combine(TestContext.CurrentContext.TestDirectory, @"TestData\PsalterMigration\1");

            manager.MigratePsalms(new PsalterRuReader(folderPath, "cs-ru"));

            manager.MigratePsalms(new PsalterCsReader(folderPath, "cs-cs"));

            //uof.Commit();
        }
        public void PsalmsMigrationManager_Test()
        {
            var uof     = new EFUnitOfWork();
            var service = new FakePsalterService(uof);

            var manager = new PsalmsMigrationManager(service);

            string folderPath = Path.Combine(TestContext.CurrentContext.TestDirectory, @"TestData\PsalterMigration");

            manager.MigratePsalms(new PsalterRuReader(folderPath, "cs-ru"));

            Assert.That(service.Psalms.Count(), Is.EqualTo(150));

            //uof.Commit();
        }