Tried to debug a problem; it turned out the problem was that my mismatch threshold was 0. Edit counting ad mismatch counting both seem to work as specified.