We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b7ec900 commit 67ba040Copy full SHA for 67ba040
tests/duplicates/test_duplicates.py
@@ -134,6 +134,20 @@ def test_find_duplicates(self):
134
135
tmp.cleanup()
136
137
+ def test_find_duplicates_symlinks(self):
138
+ """Check that we ignore symlinks when identifying duplicates."""
139
+ tmp = tempfile.TemporaryDirectory()
140
+ path = Path(tmp.name)
141
+ with open(path / "foo.cpp", mode="w") as f:
142
+ f.write("void foo();")
143
+ os.symlink(path / "foo.cpp", path / "bar.cpp")
144
+ codebase = CodeBase(path)
145
+
146
+ duplicates = find_duplicates(codebase)
147
+ self.assertEqual(duplicates, [])
148
149
+ tmp.cleanup()
150
151
152
if __name__ == "__main__":
153
unittest.main()
0 commit comments