Ejemplo n.º 1
0
            public void Should_Throw_NotSupportedException_When_Value_Is_Not_A_Valid_Directory_Path()
            {
                var converter = new DirectoryPathConverter();

                var result = Record.Exception(() => converter.ConvertFrom(DateTime.Now));

                Assert.IsType <NotSupportedException>(result);
            }
Ejemplo n.º 2
0
            public void Should_Convert_String_Value_To_Directory_Path()
            {
                var converter = new DirectoryPathConverter();

                var result = converter.ConvertFrom("c:/data/work");

                Assert.IsType <DirectoryPath>(result);
                Assert.Equal("c:/data/work", ((DirectoryPath)result).FullPath);
            }