Example #1
0
        /// <summary>
        /// Verifies that the Merchello Version (binary) is consistent with the configuration version.
        /// </summary>
        /// <remarks>
        /// This process also does database schema migrations (for Merchello) if necessary
        /// </remarks>
        private void VerifyMerchelloVersion(ApplicationContext context)
        {
            LogHelper.Info <UmbracoApplicationEventHandler>("Verifying Merchello Version.");
            var manager = new WebMigrationManager(context);

            manager.Upgraded += MigrationManagerOnUpgraded;
            manager.EnsureMerchelloVersion();
        }
Example #2
0
        /// <summary>
        /// The ensure database.
        /// </summary>
        protected void EnsureDatabase()
        {
            Logger.Info <WebBootManager>("Verifying Merchello Database is present.");
            var manager = new WebMigrationManager();

            if (!manager.EnsureDatabase())
            {
                Logger.Info <WebBootManager>("Merchello database tables installed");
            }
        }
Example #3
0
 /// <summary>
 /// The ensure database.
 /// </summary>
 protected void EnsureDatabase()
 {
     Logger.Info<WebBootManager>("Verifying Merchello Database is present.");
     var database = GetDatabase();
     var manager = new WebMigrationManager(database, SqlSyntax, Logger);
     if (!manager.EnsureDatabase())
     {
         Logger.Info<WebBootManager>("Merchello database tables installed");
     }
 }
 /// <summary>
 /// Verifies that the Merchello Version (binary) is consistent with the configuration version.
 /// </summary>
 /// <remarks>
 /// This process also does database schema migrations (for Merchello) if necessary
 /// </remarks>
 private void VerifyMerchelloVersion()
 {
     LogHelper.Info<UmbracoApplicationEventHandler>("Verifying Merchello Version.");
     var migrationManager = new WebMigrationManager();
     migrationManager.Upgraded += MigrationManagerOnUpgraded;
     migrationManager.EnsureMerchelloVersion();
 }
Example #5
0
 //[Test]
 public void Can_EnsureDatabaseIsInstalled()
 {
     var manager = new WebMigrationManager(_database, _sqlSyntax, _logger);
     var installed = manager.EnsureDatabase();
     Assert.IsTrue(installed);
 }