public void CloneTest() { IPathContainer container1 = new PathContainer(); Path dummyPath1 = MockRepository.GenerateMock <Path>(); Path dummyPath2 = MockRepository.GenerateMock <Path>(); dummyPath1.Stub(x => x.Equals(Arg <Path> .Is.Anything)).Return(true); dummyPath2.Stub(x => x.Equals(Arg <Path> .Is.Anything)).Return(true); container1.AddPath(dummyPath1); container1.AddPath(dummyPath2); IPathContainer container2 = container1.Clone(); Assert.True(container1.Equals(container2)); Assert.False(container1 == container2); }