Changeset 251450 in webkit
- Timestamp:
- Oct 22, 2019, 1:40:06 PM (6 years ago)
- Location:
- trunk/Tools
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Tools/BuildSlaveSupport/ews-build/steps.py
r251167 r251450 37 37 BUG_SERVER_URL = 'https://bugs.webkit.org/' 38 38 S3URL = 'https://s3-us-west-2.amazonaws.com/' 39 EWS_URL = 'https://ews-build.webkit.org/' 39 40 WithProperties = properties.WithProperties 40 41 Interpolate = properties.Interpolate … … 1298 1299 description = ['downloading built product'] 1299 1300 descriptionDone = ['Downloaded built product'] 1300 haltOnFailure = True 1301 flunkOnFailure = True 1301 flunkOnFailure = False 1302 1302 1303 1303 def getResultSummary(self): … … 1308 1308 def __init__(self, **kwargs): 1309 1309 super(DownloadBuiltProduct, self).__init__(logEnviron=False, **kwargs) 1310 1311 def evaluateCommand(self, cmd): 1312 rc = shell.ShellCommand.evaluateCommand(self, cmd) 1313 if rc == FAILURE: 1314 self.build.addStepsAfterCurrentStep([DownloadBuiltProductFromMaster()]) 1315 return rc 1316 1317 1318 class DownloadBuiltProductFromMaster(DownloadBuiltProduct): 1319 command = ['python', 'Tools/BuildSlaveSupport/download-built-product', 1320 WithProperties('--%(configuration)s'), 1321 WithProperties(EWS_URL + 'archives/%(fullPlatform)s-%(architecture)s-%(configuration)s/%(patch_id)s.zip')] 1322 haltOnFailure = True 1323 flunkOnFailure = True 1324 1325 def getResultSummary(self): 1326 if self.results != SUCCESS: 1327 return {u'step': u'Failed to download built product from build master'} 1328 return shell.ShellCommand.getResultSummary(self) 1329 1330 def evaluateCommand(self, cmd): 1331 return shell.ShellCommand.evaluateCommand(self, cmd) 1310 1332 1311 1333 -
trunk/Tools/BuildSlaveSupport/ews-build/steps_unittest.py
r251167 r251450 38 38 CheckOutSource, CheckOutSpecificRevision, CheckPatchRelevance, CheckStyle, CleanBuild, CleanUpGitIndexLock, CleanWorkingDirectory, 39 39 CompileJSC, CompileJSCToT, CompileWebKit, CompileWebKitToT, ConfigureBuild, 40 DownloadBuiltProduct, ExtractBuiltProduct, ExtractTestResults, InstallGtkDependencies, InstallWpeDependencies, KillOldProcesses,40 DownloadBuiltProduct, DownloadBuiltProductFromMaster, ExtractBuiltProduct, ExtractTestResults, InstallGtkDependencies, InstallWpeDependencies, KillOldProcesses, 41 41 PrintConfiguration, ReRunAPITests, ReRunJavaScriptCoreTests, ReRunWebKitTests, RunAPITests, RunAPITestsWithoutPatch, 42 42 RunBindingsTests, RunBuildWebKitOrgUnitTests, RunEWSBuildbotCheckConfig, RunEWSUnitTests, RunJavaScriptCoreTests, RunJavaScriptCoreTestsToT, RunWebKit1Tests, … … 1718 1718 ) 1719 1719 self.expectOutcome(result=FAILURE, state_string='Failed to download built product from S3') 1720 return self.runStep() 1721 1722 1723 class TestDownloadBuiltProductFromMaster(BuildStepMixinAdditions, unittest.TestCase): 1724 def setUp(self): 1725 self.longMessage = True 1726 return self.setUpBuildStep() 1727 1728 def tearDown(self): 1729 return self.tearDownBuildStep() 1730 1731 def test_success(self): 1732 self.setupStep(DownloadBuiltProductFromMaster()) 1733 self.setProperty('fullPlatform', 'ios-simulator-12') 1734 self.setProperty('configuration', 'release') 1735 self.setProperty('architecture', 'x86_64') 1736 self.setProperty('patch_id', '1234') 1737 self.expectRemoteCommands( 1738 ExpectShell(workdir='wkdir', 1739 logEnviron=False, 1740 command=['python', 'Tools/BuildSlaveSupport/download-built-product', '--release', 'https://ews-build.webkit.org/archives/ios-simulator-12-x86_64-release/1234.zip'], 1741 ) 1742 + 0, 1743 ) 1744 self.expectOutcome(result=SUCCESS, state_string='Downloaded built product') 1745 return self.runStep() 1746 1747 def test_failure(self): 1748 self.setupStep(DownloadBuiltProductFromMaster()) 1749 self.setProperty('fullPlatform', 'mac-sierra') 1750 self.setProperty('configuration', 'debug') 1751 self.setProperty('architecture', 'x86_64') 1752 self.setProperty('patch_id', '123456') 1753 self.expectRemoteCommands( 1754 ExpectShell(workdir='wkdir', 1755 logEnviron=False, 1756 command=['python', 'Tools/BuildSlaveSupport/download-built-product', '--debug', 'https://ews-build.webkit.org/archives/mac-sierra-x86_64-debug/123456.zip'], 1757 ) 1758 + ExpectShell.log('stdio', stdout='Unexpected failure.') 1759 + 2, 1760 ) 1761 self.expectOutcome(result=FAILURE, state_string='Failed to download built product from build master') 1720 1762 return self.runStep() 1721 1763 -
trunk/Tools/ChangeLog
r251439 r251450 1 2019-10-22 Aakash Jain <aakash_jain@apple.com> 2 3 [ews] Download the build archive from master when download from S3 fails 4 https://bugs.webkit.org/show_bug.cgi?id=203263 5 6 Reviewed by Jonathan Bedard. 7 8 * BuildSlaveSupport/ews-build/steps.py: 9 (DownloadBuiltProduct.evaluateCommand): 10 (DownloadBuiltProductFromMaster): Build step to download the archive from build master. 11 (DownloadBuiltProductFromMaster.getResultSummary): Added custom failure message. 12 (DownloadBuiltProductFromMaster.evaluateCommand): Overrided to ensure it doesn't use this method from base 13 class DownloadBuiltProduct. 14 * BuildSlaveSupport/ews-build/steps_unittest.py: Added unit-tests. 15 1 16 2019-10-22 youenn fablet <youenn@apple.com> 2 17
Note:
See TracChangeset
for help on using the changeset viewer.