| Differences between
and this patch
- a/Tools/CISupport/ews-build/steps.py -6 lines
Lines 5116-5127 class Canonicalize(steps.ShellSequence, ShellMixin): a/Tools/CISupport/ews-build/steps.py_sec1
5116
            return {'step': f'Failed to canonicalize {commit_pluralized}'}
5116
            return {'step': f'Failed to canonicalize {commit_pluralized}'}
5117
        return super(Canonicalize, self).getResultSummary()
5117
        return super(Canonicalize, self).getResultSummary()
5118
5118
5119
    def doStepIf(self, step):
5120
        return self.getProperty('github.number', False)
5121
5122
    def hideStepIf(self, results, step):
5123
        return not self.doStepIf(step)
5124
5125
5119
5126
class PushPullRequestBranch(shell.ShellCommand):
5120
class PushPullRequestBranch(shell.ShellCommand):
5127
    name = 'push-pull-request-branch'
5121
    name = 'push-pull-request-branch'
- a/Tools/CISupport/ews-build/steps_unittest.py -3 / +21 lines
Lines 6206-6215 class TestCanonicalize(BuildStepMixinAdditions, unittest.TestCase): a/Tools/CISupport/ews-build/steps_unittest.py_sec1
6206
    def tearDown(self):
6206
    def tearDown(self):
6207
        return self.tearDownBuildStep()
6207
        return self.tearDownBuildStep()
6208
6208
6209
    def test_skipped_patch(self):
6209
    def test_patch(self):
6210
        self.setupStep(Canonicalize())
6210
        self.setupStep(Canonicalize())
6211
        self.setProperty('patch_id', '1234')
6211
        self.setProperty('patch_id', '1234')
6212
        self.expectOutcome(result=SKIPPED, state_string='Canonicalize Commit (skipped)')
6212
6213
        self.expectRemoteCommands(
6214
            ExpectShell(
6215
                workdir='wkdir',
6216
                timeout=300,
6217
                logEnviron=False,
6218
                command=['git', 'pull', 'origin', 'main', '--rebase'],
6219
            ) + 0, ExpectShell(
6220
                workdir='wkdir',
6221
                timeout=300,
6222
                logEnviron=False,
6223
                command=['git', 'checkout', 'main'],
6224
            ) + 0, ExpectShell(
6225
                workdir='wkdir',
6226
                timeout=300,
6227
                logEnviron=False,
6228
                command=['python3', 'Tools/Scripts/git-webkit', 'canonicalize', '-n', '1'],
6229
            ) + 0,
6230
        )
6231
        self.expectOutcome(result=SUCCESS, state_string='Canonicalized commit')
6213
        return self.runStep()
6232
        return self.runStep()
6214
6233
6215
    def test_success(self):
6234
    def test_success(self):
6216
- 

Return to Bug 240461