1# -*- mode:python -*- 2# 3# Copyright (c) 2016 ARM Limited 4# All rights reserved 5# 6# The license below extends only to copyright in the software and shall 7# not be construed as granting a license to any other intellectual 8# property including but not limited to intellectual property relating --- 106 unchanged lines hidden (view full) --- 115 116 """ 117 with open(source[0].abspath, "rb") as fin: 118 result = pickle.load(fin) 119 120 assert len(result) == 1 121 result = result[0] 122 |
123 formatter = None |
124 if result.skipped(): |
125 status = color_message(termcap.Cyan, "skipped.") |
126 elif result.changed(): 127 status = color_message(termcap.Yellow, "CHANGED!") 128 formatter = results.Text() |
129 elif result: 130 status = color_message(termcap.Green, "passed.") 131 else: |
132 status = color_message(termcap.Red, "FAILED!") |
133 formatter = results.Text() 134 135 if formatter: 136 formatter.dump_suites([result]) 137 138 print "***** %s: %s" % (source[0].dir, status) 139 return 0 140 --- 15 unchanged lines hidden (view full) --- 156 ref_dir = test.ref_dir 157 158 with open(source[0].abspath, "rb") as fin: 159 result = pickle.load(fin) 160 161 assert len(result) == 1 162 result = result[0] 163 |
164 if result.skipped(): |
165 print "*** %s: %s: Test skipped, not updating." % ( 166 source[0].dir, color_message(termcap.Yellow, "WARNING"), ) 167 return 0 168 elif result: 169 print "*** %s: %s: Test successful, not updating." % ( 170 source[0].dir, color_message(termcap.Green, "skipped"), ) 171 return 0 |
172 elif result.failed_run(): |
173 print "*** %s: %s: Test failed, not updating." % ( 174 source[0].dir, color_message(termcap.Red, "ERROR"), ) 175 return 1 176 177 print "** Updating %s" % (test, ) 178 test.update_ref() 179 180 return 0 --- 68 unchanged lines hidden --- |