Fixing tests and bug in CalcRepeatability