new tests and duplicate graph detection

Improved along with many adapters.