Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(104)

Unified Diff: tools/tests/render_pictures_test.py

Issue 466153006: add --descriptions flag to render_pictures tool (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« tools/render_pictures_main.cpp ('K') | « tools/render_pictures_main.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/tests/render_pictures_test.py
diff --git a/tools/tests/render_pictures_test.py b/tools/tests/render_pictures_test.py
index a7636dc9432f21e2b6c8ffd3a6a49af19345f49b..1fdeb10f677164679c9462c393e1685ae806ec63 100755
--- a/tools/tests/render_pictures_test.py
+++ b/tools/tests/render_pictures_test.py
@@ -197,6 +197,7 @@ class RenderPicturesTest(base_unittest.TestCase):
'--writeWholeImage'])
expected_summary_dict = {
"header" : EXPECTED_HEADER_CONTENTS,
+ "descriptions" : None,
"actual-results" : {
"red.skp": {
"tiled-images": RED_TILES,
@@ -232,6 +233,7 @@ class RenderPicturesTest(base_unittest.TestCase):
modified_red_tiles[5]['comparisonResult'] = 'no-comparison'
expected_summary_dict = {
"header" : EXPECTED_HEADER_CONTENTS,
+ "descriptions" : None,
"actual-results" : {
"red.skp": {
"tiled-images": modified_red_tiles,
@@ -276,6 +278,7 @@ class RenderPicturesTest(base_unittest.TestCase):
if expected_summary_dict == None:
expected_summary_dict = {
"header" : EXPECTED_HEADER_CONTENTS,
+ "descriptions" : None,
"actual-results" : {
"red.skp": {
"whole-image": RED_WHOLEIMAGE,
@@ -300,6 +303,7 @@ class RenderPicturesTest(base_unittest.TestCase):
pass
expected_summary_dict = {
"header" : EXPECTED_HEADER_CONTENTS,
+ "descriptions" : None,
"actual-results" : {
"red.skp": {
"whole-image": modified_dict(
@@ -320,12 +324,19 @@ class RenderPicturesTest(base_unittest.TestCase):
write_path_dir = self.create_empty_dir(
path=os.path.join(self._output_dir, 'writePath'))
self._generate_skps()
- self._run_render_pictures(['-r', self._input_skp_dir,
- '--writeChecksumBasedFilenames',
- '--writePath', write_path_dir,
- '--writeJsonSummaryPath', output_json_path])
+ self._run_render_pictures([
+ '-r', self._input_skp_dir,
+ '--descriptions', 'builder=builderName', 'renderMode=renderModeName',
+ '--writeChecksumBasedFilenames',
+ '--writePath', write_path_dir,
+ '--writeJsonSummaryPath', output_json_path,
+ ])
expected_summary_dict = {
"header" : EXPECTED_HEADER_CONTENTS,
+ "descriptions" : {
+ "builder": "builderName",
+ "renderMode": "renderModeName",
+ },
"actual-results" : {
"red.skp": {
# Manually verified: 640x400 red rectangle with black border
@@ -373,6 +384,7 @@ class RenderPicturesTest(base_unittest.TestCase):
'--writeJsonSummaryPath', output_json_path])
expected_summary_dict = {
"header" : EXPECTED_HEADER_CONTENTS,
+ "descriptions" : None,
"actual-results" : {
"red.skp": {
"whole-image": RED_WHOLEIMAGE,
@@ -400,6 +412,7 @@ class RenderPicturesTest(base_unittest.TestCase):
'--writeJsonSummaryPath', output_json_path])
expected_summary_dict = {
"header" : EXPECTED_HEADER_CONTENTS,
+ "descriptions" : None,
"actual-results" : {
"red.skp": {
"tiled-images": RED_TILES,
@@ -434,6 +447,7 @@ class RenderPicturesTest(base_unittest.TestCase):
'--writeJsonSummaryPath', output_json_path])
expected_summary_dict = {
"header" : EXPECTED_HEADER_CONTENTS,
+ "descriptions" : None,
"actual-results" : {
"red.skp": {
"tiled-images": RED_TILES,
@@ -464,6 +478,7 @@ class RenderPicturesTest(base_unittest.TestCase):
'--writeJsonSummaryPath', output_json_path])
expected_summary_dict = {
"header" : EXPECTED_HEADER_CONTENTS,
+ "descriptions" : None,
"actual-results" : {
"red.skp": {
# Manually verified these 6 images, all 256x256 tiles,
@@ -589,6 +604,7 @@ class RenderPicturesTest(base_unittest.TestCase):
"""
expectations_dict = {
"header" : EXPECTED_HEADER_CONTENTS,
+ "descriptions" : None,
"expected-results" : {
# red.skp: these should fail the comparison
"red.skp": {
« tools/render_pictures_main.cpp ('K') | « tools/render_pictures_main.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698