The UK minister was heckled by spectators as she gave evidence to a Scottish Parliament committee.