*** test_GenomeDiagram_orig.py Mon Aug 13 13:36:34 2018 --- test_GenomeDiagram.py Mon Aug 13 13:36:28 2018 *************** *** 762,773 **** tracklines=False, pagesize=(10 * cm, 6 * cm), fragments=1, start=start, end=end) output_filename = os.path.join('Graphics', 'GD_region_linear.pdf') - gdd.write(output_filename, 'PDF') ! # Also check the write_to_string (bytes string) method matches, ! # (Note the possible confusion over new lines on Windows) ! assert open(output_filename, "rb").read().replace(b"\r\n", b"\n") \ ! == gdd.write_to_string('PDF').replace(b"\r\n", b"\n") output_filename = os.path.join('Graphics', 'GD_region_linear.svg') gdd.write(output_filename, 'SVG') --- 762,779 ---- tracklines=False, pagesize=(10 * cm, 6 * cm), fragments=1, start=start, end=end) output_filename = os.path.join('Graphics', 'GD_region_linear.pdf') ! oldSDE = os.environ.get('SOURCE_DATE_EPOCH',None) ! try: ! os.environ['SOURCE_DATE_EPOCH'] = '946684801' ! gdd.write(output_filename, 'PDF') ! ! # Also check the write_to_string (bytes string) method matches, ! # (Note the possible confusion over new lines on Windows) ! assert open(output_filename, "rb").read().replace(b"\r\n", b"\n") \ ! == gdd.write_to_string('PDF').replace(b"\r\n", b"\n") ! finally: ! if oldSDE: os.environ['SOURCE_DATE_EPOCH'] = oldSDE output_filename = os.path.join('Graphics', 'GD_region_linear.svg') gdd.write(output_filename, 'SVG')