Search for gamma-ray emission from supernova remnants with the Fermi/LAT and MAGIC telescopes