LCOV - code coverage report
Current view: top level - Ninject/Cqrs.Ninject.Mongo - TestMongoDataStoreConnectionStringFactory.cs Hit Total Coverage
Test: doc-coverage.info Lines: 0 3 0.0 %
Date: 2017-07-26

          Line data    Source code
       1             : #region Copyright
       2             : // // -----------------------------------------------------------------------
       3             : // // <copyright company="cdmdotnet Limited">
       4             : // //   Copyright cdmdotnet Limited. All rights reserved.
       5             : // // </copyright>
       6             : // // -----------------------------------------------------------------------
       7             : #endregion
       8             : 
       9             : using System.Configuration;
      10             : using System.Runtime.Remoting.Messaging;
      11             : using Cqrs.Mongo.Factories;
      12             : 
      13             : namespace Cqrs.Ninject.Mongo
      14             : {
      15             :         public class TestMongoDataStoreConnectionStringFactory : IMongoDataStoreConnectionStringFactory
      16           0 :         {
      17             :                 private const string MongoDbConnectionStringKey = "MongoDb-Test";
      18             : 
      19             :                 private const string CallContextDatabaseNameKey = "MongoDataStoreConnectionStringFactory¿DatabaseName";
      20             : 
      21             :                 public static string DatabaseName
      22             :                 {
      23             :                         get
      24             :                         {
      25             :                                 return (string)CallContext.GetData(CallContextDatabaseNameKey);
      26             :                         }
      27             :                         set
      28             :                         {
      29             :                                 CallContext.SetData(CallContextDatabaseNameKey, value);
      30             :                         }
      31             :                 }
      32             : 
      33           0 :                 public string GetMongoConnectionString()
      34             :                 {
      35             :                         return ConfigurationManager.ConnectionStrings[MongoDbConnectionStringKey].ConnectionString;
      36             :                 }
      37             : 
      38           0 :                 public string GetMongoDatabaseName()
      39             :                 {
      40             :                         return DatabaseName;
      41             :                 }
      42             :         }
      43             : }

Generated by: LCOV version 1.10