Active defence processes and in vitro selection for resistance to pathogens