예제 #1
0
            public void CanChangeExtensionOfPath()
            {
                // Given
                FilePath path = new FilePath("temp/hello.txt");

                // When
                path = path.ChangeExtension(".dat");

                // Then
                Assert.AreEqual("temp/hello.dat", path.ToString());
            }
예제 #2
0
            public void ShouldChangeExtension(string extension, string expected)
            {
                // Given
                FilePath path = new FilePath("temp/hello.txt");

                // When
                path = path.ChangeExtension(extension);

                // Then
                Assert.AreEqual(expected, path.ToString());
            }