public void FindCommonAncestor_ItsOwnParent_ReturnsParent() { var file = new TestableFileBase("filename.ext", parentFolder, MockFileSystem); ITreeItem commonAncestor = file.FindCommonAncestor(parentFolder); commonAncestor.ShouldEqual(parentFolder); }
public void FindCommonAncestor_NullArgument_ThrowsArgumentNullException() { var file = new TestableFileBase("filename.ext", parentFolder, MockFileSystem); Assert.Throws <ArgumentNullException>(() => file.FindCommonAncestor(null)); }
public void Constructor_WithFeature_SetsFolderProperty() { var featureFile = new TestableFileBase("filename.ext", parentFolder, MockFileSystem); featureFile.Folder.ShouldEqual(parentFolder); }
public void Constructor_FileNameWithExtension_RemovesExtension() { var featureFile = new TestableFileBase("Feature.ext", parentFolder, MockFileSystem); featureFile.Name.ShouldEqual("Feature"); }
public void Constructor_ValidFileName_SetsNameProperty() { var featureFile = new TestableFileBase("Feature", parentFolder, MockFileSystem); featureFile.Name.ShouldEqual("Feature"); }
public void FindCommonAncestor_NullArgument_ThrowsArgumentNullException() { var file = new TestableFileBase("filename.ext", parentFolder); Assert.Throws<ArgumentNullException>(() => file.FindCommonAncestor(null)); }
public void FindCommonAncestor_ItsOwnParent_ReturnsParent() { var file = new TestableFileBase("filename.ext", parentFolder); ITreeItem commonAncestor = file.FindCommonAncestor(parentFolder); commonAncestor.ShouldEqual(parentFolder); }
public void Constructor_WithFeature_SetsFolderProperty() { var featureFile = new TestableFileBase("filename.ext", parentFolder); featureFile.Folder.ShouldEqual(parentFolder); }
public void Constructor_ValidFileName_SetsNameProperty() { var featureFile = new TestableFileBase("Feature", parentFolder); featureFile.Name.ShouldEqual("Feature"); }
public void Constructor_FileNameWithExtension_RemovesExtension() { var featureFile = new TestableFileBase("Feature.ext", parentFolder); featureFile.Name.ShouldEqual("Feature"); }