The plan will detect community transmission of the coronavirus in the event of an outbreak in Scotland.