SConscript (11504:f3184dd8257f) | SConscript (11542:ecd058e3dcbe) |
---|---|
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 | 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 run = result.results[0] 124 assert run.name == "gem5" 125 | |
126 formatter = None | 123 formatter = None |
127 if not run: 128 status = color_message(termcap.Red, "FAILED!") 129 formatter = results.Text() 130 elif run.skipped(): | 124 if result.skipped(): |
131 status = color_message(termcap.Cyan, "skipped.") | 125 status = color_message(termcap.Cyan, "skipped.") |
126 elif result.changed(): 127 status = color_message(termcap.Yellow, "CHANGED!") 128 formatter = results.Text() |
|
132 elif result: 133 status = color_message(termcap.Green, "passed.") 134 else: | 129 elif result: 130 status = color_message(termcap.Green, "passed.") 131 else: |
135 status = color_message(termcap.Yellow, "CHANGED!") | 132 status = color_message(termcap.Red, "FAILED!") |
136 formatter = results.Text() 137 138 if formatter: 139 formatter.dump_suites([result]) 140 141 print "***** %s: %s" % (source[0].dir, status) 142 return 0 143 --- 15 unchanged lines hidden (view full) --- 159 ref_dir = test.ref_dir 160 161 with open(source[0].abspath, "rb") as fin: 162 result = pickle.load(fin) 163 164 assert len(result) == 1 165 result = result[0] 166 | 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 |
167 run = result.results[0] 168 assert run.name == "gem5" 169 170 if run.skipped(): | 164 if result.skipped(): |
171 print "*** %s: %s: Test skipped, not updating." % ( 172 source[0].dir, color_message(termcap.Yellow, "WARNING"), ) 173 return 0 174 elif result: 175 print "*** %s: %s: Test successful, not updating." % ( 176 source[0].dir, color_message(termcap.Green, "skipped"), ) 177 return 0 | 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 |
178 elif not run.success(): | 172 elif result.failed_run(): |
179 print "*** %s: %s: Test failed, not updating." % ( 180 source[0].dir, color_message(termcap.Red, "ERROR"), ) 181 return 1 182 183 print "** Updating %s" % (test, ) 184 test.update_ref() 185 186 return 0 --- 68 unchanged lines hidden --- | 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 --- |