Bug 70143

Summary: Write unit test to ensure style-checker-filter option is passed properly in webkit-patch
Product: WebKit Reporter: Dimitri Glazkov (Google) <dglazkov>
Component: Tools / TestsAssignee: Dimitri Glazkov (Google) <dglazkov>
Status: RESOLVED FIXED    
Severity: Normal CC: abarth
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on: 70119    
Bug Blocks:    
Attachments:
Description Flags
Patch abarth: review+, abarth: commit-queue-

Description Dimitri Glazkov (Google) 2011-10-14 14:14:16 PDT
From the comment: https://bugs.webkit.org/show_bug.cgi?id=70119#c2
Comment 1 Dimitri Glazkov (Google) 2011-10-14 15:14:52 PDT
Created attachment 111091 [details]
Patch
Comment 2 Adam Barth 2011-10-14 15:25:09 PDT
Comment on attachment 111091 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=111091&action=review

> Tools/Scripts/webkitpy/tool/commands/download_unittest.py:128
> +        expected_stderr = "MOCK run_and_throw_if_fail: ['mock-prepare-ChangeLog', '--email=MOCK email', '--merge-base=None', 'MockFile1'], cwd=/mock-checkout\nMOCK run_and_throw_if_fail: ['mock-check-webkit-style', '--git-commit', 'MOCK git commit', '--diff-files', 'MockFile1', '--filter', '-changelog'], cwd=/mock-checkout\nMOCK run_command: ['ruby', '-I', '/mock-checkout/Websites/bugs.webkit.org/PrettyPatch', '/mock-checkout/Websites/bugs.webkit.org/PrettyPatch/prettify.rb'], cwd=None\nMOCK: user.open_url: file://...\nWas that diff correct?\nBuilding WebKit\nMOCK run_and_throw_if_fail: ['mock-build-webkit'], cwd=/mock-checkout\nRunning Python unit tests\nMOCK run_and_throw_if_fail: ['mock-test-webkitpy'], cwd=/mock-checkout\nRunning Perl unit tests\nMOCK run_and_throw_if_fail: ['mock-test-webkitperl'], cwd=/mock-checkout\nRunning Bindings tests\nMOCK run_and_throw_if_fail: ['mock-run-bindings-tests'], cwd=/mock-checkout\nRunning JavaScriptCore tests\nMOCK run_and_throw_if_fail: ['mock-run-javacriptcore-tests'], cwd=/mock-checkout\nRunning run-webkit-tests\nMOCK run_and_throw_if_fail: ['mock-run-webkit-tests', '--quiet'], cwd=/mock-checkout\nCommitted r49824: <http://trac.webkit.org/changeset/49824>\nCommitted r49824: <http://trac.webkit.org/changeset/49824>\nNo bug id provided.\n"

We usually use heredoc style strings (you know, with """ quotes) so we can have each line of the string be on a separate line of source.  That makes the expected results more readable and makes it easier to see the diffs.
Comment 3 Adam Barth 2011-10-14 15:25:47 PDT
Comment on attachment 111091 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=111091&action=review

> Tools/Scripts/webkitpy/tool/steps/checkstyle.py:60
> -            args.extend(self._options.check_style_filter)
> +            args.append(self._options.check_style_filter)

boogs!
Comment 4 Dimitri Glazkov (Google) 2011-10-14 15:36:20 PDT
Committed r97521: <http://trac.webkit.org/changeset/97521>