public void Provider_WhenProviderNameIsSql2008_ValueIsReflectedInProperty() { var connectionStringFake = new Mock<IConnectionString>(); connectionStringFake.Setup(f => f.Provider).Returns(StorageProviders.Sql2008.ToString()); var connectionInfo = new SisoConnectionInfoImplementation(connectionStringFake.Object); Assert.AreEqual(StorageProviders.Sql2008, connectionInfo.ProviderType); }
public void BackgroundIndexing_WhenNoValueIsSpecified_ValueBecomesOff() { var connectionStringFake = new Mock<IConnectionString>(); connectionStringFake.Setup(f => f.Provider).Returns(StorageProviders.Sql2008.ToString()); connectionStringFake.Setup(f => f.BackgroundIndexing).Returns(null as string); var connectionInfo = new SisoConnectionInfoImplementation(connectionStringFake.Object); Assert.AreEqual(BackgroundIndexing.Off, connectionInfo.BackgroundIndexing); }