Ejemplo n.º 1
0
            public void ReturnsCorrectDirectoryPathForDirectoryPath(string path, string expected)
            {
                // Given
                MetadataDictionary initialMetadata = new MetadataDictionary();
                MetadataStack      metadata        = new MetadataStack(initialMetadata);

                // When
                metadata = metadata.Clone(new[] { new KeyValuePair <string, object>("A", new DirectoryPath(path)) });
                object result = metadata.DirectoryPath("A");

                // Then
                Assert.IsInstanceOf <DirectoryPath>(result);
                Assert.AreEqual(expected, ((DirectoryPath)result).FullPath);
            }
Ejemplo n.º 2
0
 public DirectoryPath DirectoryPath(string key, DirectoryPath defaultValue = null) => _metadata.DirectoryPath(key, defaultValue);