public virtual IMessageWriter CreateMessageWriter(ClientStoreType type)
 {
     IMessageWriter writer = null;
     switch (type)
     {
         case ClientStoreType.DATABASE:
             writer = new DatabaseWriter();
             break;
         default:
             throw new NotImplementedException("The ClientStoreType does not exist. Please Implement in API");
     }
     return writer;
 }
 public void MessageWriterFactory_CreateDatabaseWriter()
 {
     //arrange
     var HelloWorld = new MessageWriterFactory();
     var controlled = new DatabaseWriter();
     //act
     var writer = HelloWorld.CreateMessageWriter(ClientStoreType.DATABASE);
     //assert
     Assert.AreEqual(controlled, writer);
 }
 public void DatabaseWriter_NotImplemented()
 {
     var HelloWorld = new DatabaseWriter();
     HelloWorld.Write();
 }