Description: upstream: fix deprecation: time Substitute time.clock(), which is deprecated since version 3.3, by time.process_time(), which seems here more appropriate than its alternative time.perf_counter(), when Python3 (or higher) is used. See https://docs.python.org/3/library/time.html for details. Origin: vendor, Debian Forwarded: NA Author: Jerome Benoit Last-Update: 2018-12-01 --- a/CommonMark/test/test-CommonMark.py +++ b/CommonMark/test/test-CommonMark.py @@ -75,7 +75,10 @@ current_section = "" -startTime = time.clock() +if sys.version_info[0] < 3: + startTime = time.clock() +else: + startTime = time.process_time() if args.i: print(colors.OKGREEN+"(To end input of Markdown block enter 'end' on it's own line, to quit enter 'quit')"+colors.ENDC) @@ -146,7 +149,12 @@ print(str(passed)+" tests passed, "+str(failed)+" failed") -endTime = time.clock() + +if sys.version_info[0] < 3: + endTime = time.clock() +else: + endTime = time.process_time() + runTime = endTime-startTime if args.s: