Bug 64508 - Move webkitpy off of loose mocks
Summary: Move webkitpy off of loose mocks
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Eric Seidel (no email)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-07-13 19:41 PDT by Eric Seidel (no email)
Modified: 2011-07-14 19:33 PDT (History)
3 users (show)

See Also:


Attachments
Patch (29.65 KB, patch)
2011-07-13 19:43 PDT, Eric Seidel (no email)
no flags Details | Formatted Diff | Diff
Patch (33.51 KB, patch)
2011-07-13 21:04 PDT, Eric Seidel (no email)
abarth: review+
eric: commit-queue?
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Eric Seidel (no email) 2011-07-13 19:41:41 PDT
Move webkitpy off of loose mocks
Comment 1 Eric Seidel (no email) 2011-07-13 19:43:17 PDT
Created attachment 100757 [details]
Patch
Comment 2 Eric Seidel (no email) 2011-07-13 19:43:37 PDT
Still needs a little lovin to pass all the unit tests.
Comment 3 Adam Barth 2011-07-13 19:49:05 PDT
Comment on attachment 100757 [details]
Patch

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

> Tools/Scripts/webkitpy/tool/steps/cleanworkingdirectory_unittest.py:39
> +        tool._scm = Mock()

wait!  this is a loose mock!
Comment 4 Eric Seidel (no email) 2011-07-13 21:04:36 PDT
Created attachment 100763 [details]
Patch
Comment 5 Adam Barth 2011-07-13 21:42:51 PDT
Comment on attachment 100763 [details]
Patch

Very nice.
Comment 6 Eric Seidel (no email) 2011-07-13 22:05:19 PDT
Committed r90978: <http://trac.webkit.org/changeset/90978>
Comment 7 Kent Tamura 2011-07-14 18:07:13 PDT
Comment on attachment 100763 [details]
Patch

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

> Tools/Scripts/webkitpy/common/checkout/scm/git.py:111
>      @classmethod
>      def to_object_name(cls, filepath):
> -        root_end_with_slash = os.path.join(cls.find_checkout_root(os.path.dirname(filepath)), '')
> +        root_end_with_slash = self._filesystem.join(cls.find_checkout_root(self._filesystem.dirname(filepath)), '')

File "/Volumes/d2/WebKit/Tools/Scripts/webkitpy/common/checkout/scm/git.py", line 111, in to_object_name
    root_end_with_slash = self._filesystem.join(cls.find_checkout_root(self._filesystem.dirname(filepath)), '')
NameError: global name 'self' is not defined

rebaseline-chromium-webkit-tests doesn't work because of this error.
Comment 8 Eric Seidel (no email) 2011-07-14 19:07:52 PDT
Sorry.  I wish rebaseline-chromium-tests has more unittesting... this is the second typo from that change which broke rebaseline-chromium-tests.
Comment 9 Eric Seidel (no email) 2011-07-14 19:33:55 PDT
Committed r91045: <http://trac.webkit.org/changeset/91045>