OLD | NEW |
1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 | 5 |
6 """Utility class to build the Skia master BuildFactory's. | 6 """Utility class to build the Skia master BuildFactory's. |
7 | 7 |
8 Based on gclient_factory.py and adds Skia-specific steps.""" | 8 Based on gclient_factory.py and adds Skia-specific steps.""" |
9 | 9 |
10 | 10 |
(...skipping 425 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
436 def Install(self): | 436 def Install(self): |
437 """ Install the compiled executables. """ | 437 """ Install the compiled executables. """ |
438 self.AddFlavoredSlaveScript(script='install.py', description='Install', | 438 self.AddFlavoredSlaveScript(script='install.py', description='Install', |
439 halt_on_failure=True) | 439 halt_on_failure=True) |
440 | 440 |
441 def DownloadSKPs(self): | 441 def DownloadSKPs(self): |
442 """ Download the SKPs. """ | 442 """ Download the SKPs. """ |
443 self.AddSlaveScript(script='download_skps.py', description='DownloadSKPs', | 443 self.AddSlaveScript(script='download_skps.py', description='DownloadSKPs', |
444 halt_on_failure=True) | 444 halt_on_failure=True) |
445 | 445 |
| 446 def DownloadSKImageFiles(self): |
| 447 """ Download image files for running skimage. """ |
| 448 self.AddSlaveScript(script='download_skimage_files.py', |
| 449 description='DownloadSKImageFiles', |
| 450 halt_on_failure=True) |
| 451 |
446 def DownloadBaselines(self): | 452 def DownloadBaselines(self): |
447 """ Download the GM baselines. """ | 453 """ Download the GM baselines. """ |
448 self.AddSlaveScript(script='download_baselines.py', | 454 self.AddSlaveScript(script='download_baselines.py', |
449 description='DownloadBaselines', halt_on_failure=True) | 455 description='DownloadBaselines', halt_on_failure=True) |
450 | 456 |
451 def RunTests(self): | 457 def RunTests(self): |
452 """ Run the unit tests. """ | 458 """ Run the unit tests. """ |
453 self.AddFlavoredSlaveScript(script='run_tests.py', description='RunTests') | 459 self.AddFlavoredSlaveScript(script='run_tests.py', description='RunTests') |
454 | 460 |
| 461 def RunDecodingTests(self): |
| 462 """ Run tests of image decoders. """ |
| 463 self.AddFlavoredSlaveScript(script='run_decoding_tests.py', |
| 464 description='RunDecodingTests') |
| 465 |
455 def RunGM(self): | 466 def RunGM(self): |
456 """ Run the "GM" tool, saving the images to disk. """ | 467 """ Run the "GM" tool, saving the images to disk. """ |
457 self.AddFlavoredSlaveScript(script='run_gm.py', description='GenerateGMs', | 468 self.AddFlavoredSlaveScript(script='run_gm.py', description='GenerateGMs', |
458 is_rebaseline_step=True) | 469 is_rebaseline_step=True) |
459 | 470 |
460 def PreRender(self): | 471 def PreRender(self): |
461 """ Step to run before the render steps. """ | 472 """ Step to run before the render steps. """ |
462 self.AddFlavoredSlaveScript(script='prerender.py', description='PreRender') | 473 self.AddFlavoredSlaveScript(script='prerender.py', description='PreRender') |
463 | 474 |
464 def RenderPictures(self): | 475 def RenderPictures(self): |
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
612 | 623 |
613 | 624 |
614 def UploadGMResults(self): | 625 def UploadGMResults(self): |
615 """ Upload the images generated by GM """ | 626 """ Upload the images generated by GM """ |
616 args = ['--autogen_svn_username_file', self._autogen_svn_username_file, | 627 args = ['--autogen_svn_username_file', self._autogen_svn_username_file, |
617 '--autogen_svn_password_file', self._autogen_svn_password_file] | 628 '--autogen_svn_password_file', self._autogen_svn_password_file] |
618 self.AddSlaveScript(script='upload_gm_results.py', args=args, | 629 self.AddSlaveScript(script='upload_gm_results.py', args=args, |
619 description='UploadGMResults', timeout=5400, | 630 description='UploadGMResults', timeout=5400, |
620 is_rebaseline_step=True) | 631 is_rebaseline_step=True) |
621 | 632 |
| 633 def UploadSKImageResults(self): |
| 634 self.AddSlaveScript(script='upload_skimage_results.py', |
| 635 description="UploadSKImageResults") |
| 636 |
622 def CommonSteps(self, clobber=None): | 637 def CommonSteps(self, clobber=None): |
623 """ Steps which are run at the beginning of all builds. """ | 638 """ Steps which are run at the beginning of all builds. """ |
624 self.UpdateSteps() | 639 self.UpdateSteps() |
625 self.DownloadSKPs() | 640 self.DownloadSKPs() |
626 self.Compile(clobber) | 641 self.Compile(clobber) |
627 self.Install() | 642 self.Install() |
628 | 643 |
629 def NonPerfSteps(self): | 644 def NonPerfSteps(self): |
630 """ Add correctness testing BuildSteps. """ | 645 """ Add correctness testing BuildSteps. """ |
631 self.DownloadBaselines() | 646 self.DownloadBaselines() |
| 647 self.DownloadSKImageFiles() |
632 self.PreRender() | 648 self.PreRender() |
633 self.RunTests() | 649 self.RunTests() |
634 self.RunGM() | 650 self.RunGM() |
635 self.RenderPictures() | 651 self.RenderPictures() |
636 self.RenderPdfs() | 652 self.RenderPdfs() |
| 653 self.RunDecodingTests() |
637 self.PostRender() | 654 self.PostRender() |
638 if self._do_upload_results: | 655 if self._do_upload_results: |
639 self.UploadGMResults() | 656 self.UploadGMResults() |
640 self.CompareAndUploadWebpageGMs() | 657 self.CompareAndUploadWebpageGMs() |
| 658 self.UploadSKImageResults() |
641 self.CompareGMs() | 659 self.CompareGMs() |
642 | 660 |
643 def PerfSteps(self): | 661 def PerfSteps(self): |
644 """ Add performance testing BuildSteps. """ | 662 """ Add performance testing BuildSteps. """ |
645 self.PreBench() | 663 self.PreBench() |
646 self.RunBench() | 664 self.RunBench() |
647 self.BenchPictures() | 665 self.BenchPictures() |
648 self.PostBench() | 666 self.PostBench() |
649 self.CheckForRegressions() | 667 self.CheckForRegressions() |
650 self.BenchGraphs() | 668 self.BenchGraphs() |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
689 # Perf-only builder. | 707 # Perf-only builder. |
690 if not self._perf_output_basedir: | 708 if not self._perf_output_basedir: |
691 raise ValueError( | 709 raise ValueError( |
692 'BuildPerfOnly requires perf_output_basedir to be defined.') | 710 'BuildPerfOnly requires perf_output_basedir to be defined.') |
693 if self._configuration != CONFIG_RELEASE: | 711 if self._configuration != CONFIG_RELEASE: |
694 raise ValueError('BuildPerfOnly should run in %s configuration.' % | 712 raise ValueError('BuildPerfOnly should run in %s configuration.' % |
695 CONFIG_RELEASE) | 713 CONFIG_RELEASE) |
696 self.PerfSteps() | 714 self.PerfSteps() |
697 self.Validate() | 715 self.Validate() |
698 return self | 716 return self |
OLD | NEW |