示例#1
0
        public void PathSegmentCountCanBeStoredAndRead()
        {
            // Arrange

            const int pathSegmentCount = 7;
            var       repository       = new StoredSettingsRepository();

            // Act

            repository.SetPathSegmentCount(pathSegmentCount);

            // Assert

            ReloadData();

            var storedValue = repository.GetPathSegmentCount();

            Assert.That(storedValue, Is.EqualTo(pathSegmentCount));
        }
示例#2
0
        public void PathSegmentCountCanBeReset()
        {
            // Arrange

            const int defaultValue = 1;

            var repository = new StoredSettingsRepository();

            repository.SetPathSegmentCount(7);

            // Act

            repository.Reset();

            // Assert

            var storedValue = repository.GetPathSegmentCount();

            Assert.That(storedValue, Is.EqualTo(defaultValue));
        }