Skip to content

Commit

Permalink
Removed some warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
erikbra committed Oct 29, 2017
1 parent dd38f56 commit 2d783d0
Show file tree
Hide file tree
Showing 8 changed files with 6 additions and 11 deletions.
1 change: 0 additions & 1 deletion product/roundhouse.console/Program.cs
Expand Up @@ -615,7 +615,6 @@ private static RoundhouseMigrationRunner get_migration_runner(ConfigurationPrope
configuration.Drop,
configuration.DoNotCreateDatabase,
configuration.WithTransaction,
configuration.RecoveryModeSimple,
configuration);
}

Expand Down
2 changes: 2 additions & 0 deletions product/roundhouse.databases.sqlserver/SqlServerDatabase.cs
Expand Up @@ -111,13 +111,15 @@ public void create_roundhouse_schema_if_it_doesnt_exist()
{
run_sql(create_roundhouse_schema_script(),ConnectionType.Default);
}
#pragma warning disable 168
catch (Exception ex)
{
throw;
//Log.bound_to(this).log_a_warning_event_containing(
// "Either the schema has already been created OR {0} with provider {1} does not provide a facility for creating roundhouse schema at this time.{2}{3}",
// GetType(), provider, Environment.NewLine, ex.Message);
}
#pragma warning restore 168
}

public string create_roundhouse_schema_script()
Expand Down
1 change: 0 additions & 1 deletion product/roundhouse.tasks/Roundhouse.cs
Expand Up @@ -229,7 +229,6 @@ public void run_the_task()
Drop,
DoNotCreateDatabase,
WithTransaction,
RecoveryModeSimple,
this);

roundhouse_runner.run();
Expand Down
Expand Up @@ -39,7 +39,6 @@ public when_nhibernate_session_factory_is_created_for_sql_server()
private static void get_schema_export(Configuration cfg)
{
build_schema(cfg);
int i = 0;
}

[Observation]
Expand Down
@@ -1,3 +1,4 @@
using System;
using System.Collections.Generic;

namespace roundhouse.tests.infrastructure.app.tokens
Expand Down Expand Up @@ -52,13 +53,13 @@ public void if_given_a_value_that_is_the_name_of_a_configuration_item_but_is_not
TokenReplacer.replace_tokens(configuration, "ALTER DATABASE DatabaseName").should_be_equal_to("ALTER DATABASE DatabaseName");
}

[Observation]
[Observation, CLSCompliant(false)]
public void if_given_bracket_bracket_databasename_bracket_bracket_should_replace_with_the_DatabaseName_from_the_configuration()
{
TokenReplacer.replace_tokens(configuration, "ALTER DATABASE {{databasename}}").should_be_equal_to("ALTER DATABASE " + database_name);
}

[Observation]
[Observation, CLSCompliant(false)]
public void if_given_bracket_bracket_DATABASENAME_bracket_bracket_should_replace_with_the_DatabaseName_from_the_configuration()
{
TokenReplacer.replace_tokens(configuration, "ALTER DATABASE {{DATABASENAME}}").should_be_equal_to("ALTER DATABASE " + database_name);
Expand Down
Expand Up @@ -28,7 +28,7 @@ protected concern_for_migrator_runner()
{
configuration = new DefaultConfiguration
{
EnvironmentName = "TEST",
EnvironmentNames = "TEST",
Drop = false ,
Silent = true
};
Expand Down Expand Up @@ -56,7 +56,6 @@ protected concern_for_migrator_runner()
configuration.Drop,
configuration.DoNotCreateDatabase,
configuration.WithTransaction,
configuration.RecoveryModeSimple,
configuration);

var container_mock = new Mock<InversionContainer>();
Expand Down
1 change: 0 additions & 1 deletion product/roundhouse/Migrate.cs
Expand Up @@ -116,7 +116,6 @@ private RoundhouseMigrationRunner GetMigrationRunner()
this.configuration.Drop,
this.configuration.DoNotCreateDatabase,
this.configuration.WithTransaction,
this.configuration.RecoveryModeSimple,
this.configuration);
}

Expand Down
3 changes: 0 additions & 3 deletions product/roundhouse/runners/RoundhouseMigrationRunner.cs
Expand Up @@ -25,7 +25,6 @@ public sealed class RoundhouseMigrationRunner : IRunner
public bool dropping_the_database { get; set; }
private readonly bool dont_create_the_database;
private bool run_in_a_transaction;
private readonly bool use_simple_recovery;
private readonly ConfigurationPropertyHolder configuration;
private const string SQL_EXTENSION = "*.sql";

Expand All @@ -40,7 +39,6 @@ public sealed class RoundhouseMigrationRunner : IRunner
bool dropping_the_database,
bool dont_create_the_database,
bool run_in_a_transaction,
bool use_simple_recovery,
ConfigurationPropertyHolder configuration)
{
this.known_folders = known_folders;
Expand All @@ -53,7 +51,6 @@ public sealed class RoundhouseMigrationRunner : IRunner
this.dropping_the_database = dropping_the_database;
this.dont_create_the_database = dont_create_the_database;
this.run_in_a_transaction = run_in_a_transaction;
this.use_simple_recovery = use_simple_recovery;
this.configuration = configuration;
}

Expand Down

0 comments on commit 2d783d0

Please sign in to comment.