Exemple #1
0
        public void GetBsonReaderSettingsDefaults()
        {
            var factory        = new SerializationFactory();
            var readerSettings = factory.GetBsonReaderSettings(typeof(int));

            Assert.AreEqual(readerSettings.ReadLocalTime, true);
            Assert.IsNotNull(readerSettings.Builder);
        }
Exemple #2
0
        public void ReadLocalTimeCanBeChangedByConfig()
        {
            var factory = new SerializationFactory(new MongoConfiguration {
                ReadLocalTime = false
            });
            var readerSettings = factory.GetBsonReaderSettings(typeof(int));

            Assert.AreEqual(readerSettings.ReadLocalTime, false);
        }