IdrisDoc tests + bug fix

This is tests for IdrisDoc as promised earlier.
While writing them I found a bug related to merging documentations, which I fixed while at it.

Since #1098 the run_backup files have been removed, and the tests have been converted to pure bash scripts to eliminate dependency problems with the added benefit of running faster.