jdupes icon indicating copy to clipboard operation
jdupes copied to clipboard

Test suite?

Open Freaky opened this issue 7 years ago • 2 comments

I notice the Makefile has a test target, but it points at a non-existing test.sh.

compare_jdupes.sh doesn't work properly, since the output of each group of files differs (this in itself seems to be a regression from expectations), and it's kind of an ad-hoc test anyway.

dupd has a fairly extensive test suite, which I've found very useful as a port maintainer. Might be worth adapting that?

Freaky avatar Aug 06 '18 15:08 Freaky

Testing relies on stable reproducible results and I'm not willing to put in the work on the existing code base to make that happen. I'm rewriting from scratch for 2.0 and there will be far too many possible combinations of options to test, never mind the issues with cross-platform path names adding to the pain. That's why I dumped the test suite. The compare_jdupes.sh script exists solely to compare output for an existing known-working jdupes against the working tree to make sure that something has not gone horribly wrong; it's for sanity checking during development rather than actually comparing two significantly different versions of the program.

dupd works in a radically different way from most other duplicate scanners: you put file information into a database and results are extracted from the database. If you have a DB engine under the hood, it's dead simple to produce stable output. dupd also doesn't run on Windows which adds even more complexity to the problem.

I'm not personally adding a test suite to any future 1.x versions, though I may entertain the idea for 2.0 and later.

jbruchon avatar Aug 06 '18 22:08 jbruchon

For sanity checking travis could help to run build on various system for commons scenario.

gagarine avatar Sep 20 '20 13:09 gagarine