From ba551776422b538e6a4ac44b2af14079fbfc59af Mon Sep 17 00:00:00 2001 From: "maruel@chromium.org" Date: Wed, 3 Feb 2010 18:21:42 +0000 Subject: [PATCH] Fix licensing headers and move most third party code to third_party/ Moved tests/pymox to third_party/pymox Moved upload.py to third_party/upload.py Fixed tests so they can run standalone Fixed the executable bit on some scripts TEST=none BUG=34376 Review URL: http://codereview.chromium.org/562031 git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@37987 0039d316-1c4b-4281-b951-d872f2087c98 --- PRESUBMIT.py | 1 - README | 9 +- README.git-cl | 52 ---------- README.git-cl.codereview | 99 ------------------- drover.py | 3 +- gcl.py | 2 +- gclient.py | 17 +--- git-try | 7 +- presubmit_canned_checks.py | 3 +- tests/README.gclient_test | 6 -- tests/gcl_unittest.py | 7 +- tests/gclient_scm_test.py | 33 +++---- tests/gclient_test.py | 24 +---- tests/gclient_utils_test.py | 9 +- tests/presubmit_unittest.py | 8 +- tests/scm_unittest.py | 10 +- tests/super_mox.py | 13 ++- tests/trychange_unittest.py | 9 +- third_party/__init__.py | 5 + {tests => third_party}/pymox/COPYING | 0 {tests => third_party}/pymox/MANIFEST.in | 0 {tests => third_party}/pymox/README | 0 {tests => third_party}/pymox/__init__.py | 0 {tests => third_party}/pymox/mox.py | 0 {tests => third_party}/pymox/mox_test.py | 0 .../pymox/mox_test_helper.py | 0 {tests => third_party}/pymox/setup.py | 0 {tests => third_party}/pymox/stubout.py | 0 {tests => third_party}/pymox/stubout_test.py | 0 .../pymox/stubout_testee.py | 0 upload.py => third_party/upload.py | 0 31 files changed, 66 insertions(+), 251 deletions(-) mode change 100755 => 100644 PRESUBMIT.py delete mode 100644 README.git-cl delete mode 100644 README.git-cl.codereview mode change 100644 => 100755 drover.py mode change 100755 => 100644 presubmit_canned_checks.py delete mode 100644 tests/README.gclient_test mode change 100644 => 100755 tests/gclient_utils_test.py mode change 100644 => 100755 tests/trychange_unittest.py create mode 100644 third_party/__init__.py rename {tests => third_party}/pymox/COPYING (100%) rename {tests => third_party}/pymox/MANIFEST.in (100%) rename {tests => third_party}/pymox/README (100%) rename {tests => third_party}/pymox/__init__.py (100%) rename {tests => third_party}/pymox/mox.py (100%) rename {tests => third_party}/pymox/mox_test.py (100%) rename {tests => third_party}/pymox/mox_test_helper.py (100%) rename {tests => third_party}/pymox/setup.py (100%) rename {tests => third_party}/pymox/stubout.py (100%) rename {tests => third_party}/pymox/stubout_test.py (100%) rename {tests => third_party}/pymox/stubout_testee.py (100%) rename upload.py => third_party/upload.py (100%) diff --git a/PRESUBMIT.py b/PRESUBMIT.py old mode 100755 new mode 100644 index 750e57b25..07c4842ca --- a/PRESUBMIT.py +++ b/PRESUBMIT.py @@ -1,4 +1,3 @@ -#!/usr/bin/python # Copyright (c) 2009 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. diff --git a/README b/README index af8ba5051..7d0af32f6 100644 --- a/README +++ b/README @@ -7,10 +7,6 @@ the latest versions of these tools as found at: This package contains: - change-svn-wc-format.py - Tool to convert from a svn checkout format to another. Fetched from - http://svn.collab.net/repos/svn/trunk/tools/client-side/change-svn-wc-format.py - chrome-update-create-task.bat Creates a scheduled task to do an automatic local chromium build every day. @@ -22,7 +18,7 @@ This package contains: A tool for uploading and managing code reviews on the Chromium project, using the Rietveld code review tool. More info at: http://code.google.com/p/rietveld/ - + gclient A script for managing a workspace with modular dependencies that are each checked out independently from different repositories. @@ -34,9 +30,6 @@ This package contains: construction tool. More info at: http://www.scons.org/ - revert - A small tool to quickly revert a change. - Note: svn and python will be installed automatically if not accessible (on Windows only). diff --git a/README.git-cl b/README.git-cl deleted file mode 100644 index 092495271..000000000 --- a/README.git-cl +++ /dev/null @@ -1,52 +0,0 @@ -# git-cl -- a git-command for integrating reviews on Rietveld -# Copyright (C) 2008 Evan Martin - -== Background -Rietveld, also known as http://codereview.appspot.com, is a nice tool -for code reviews. You upload a patch (and some other data) and it lets -others comment on your patch. - -For more on how this all works conceptually, please see README.codereview. -The remainder of this document is the nuts and bolts of using git-cl. - -== Install -Copy (symlink) it into your path somewhere, along with Rietveld -upload.py. - -== Setup -Run this from your git checkout and answer some questions: -$ git cl config - -== How to use it -Make a new branch. Write some code. Commit it locally. Send it for -review: -$ git cl upload -By default, it diffs against whatever branch the current branch is -tracking (see "git checkout --track"). An optional last argument is -passed to "git diff", allowing reviews against other heads. - -You'll be asked some questions, and the review issue number will be -associated with your current git branch, so subsequent calls to upload -will update that review rather than making a new one. - -== git-svn integration -Review looks good? Commit the code: -$ git cl dcommit -This does a git-svn dcommit, with a twist: all changes in the diff -will be squashed into a single commit, and the description of the commit -is taken directly from the Rietveld description. This command also accepts -arguments to "git diff", much like upload. -Try "git cl dcommit --help" for more options. - -== Extra commands -Print some status info: -$ git cl status - -Edit the issue association on the current branch: -$ git cl issue 1234 - -Patch in a review: -$ git cl patch -Try "git cl patch --help" for more options. - -vim: tw=72 : diff --git a/README.git-cl.codereview b/README.git-cl.codereview deleted file mode 100644 index cf1d3ad3d..000000000 --- a/README.git-cl.codereview +++ /dev/null @@ -1,99 +0,0 @@ -The git-cl README describes the git-cl command set. This document -describes how code review and git work together in general, intended -for people familiar with git but unfamiliar with the code review -process supported by Rietveld. - -== Concepts and terms -A Rietveld review is for discussion of a single change or patch. You -upload a proposed change, the reviewer comments on your change, and -then you can upload a revised version of your change. Rietveld stores -the history of uploaded patches as well as the comments, and can -compute diffs in between these patches. The history of a patch is -very much like a small branch in git, but since Rietveld is -VCS-agnostic the concepts don't map perfectly. The identifier for a -single review+patches+comments in Rietveld is called an "issue". - -Rietveld provides a basic uploader that understands git. This program -is used by git-cl, and is included in the git-cl repo as upload.py. - -== Basic interaction with git -The fundamental problem you encounter when you try to mix git and code -review is that with git it's nice to commit code locally, while during -a code review you're often requested to change something about your -code. There are a few different ways you can handle this workflow -with git: - -1) Rewriting a single commit. Say the origin commit is O, and you - commit your initial work in a commit A, making your history like - O--A. After review comments, you commit --amend, effectively - erasing A and making a new commit A', so history is now O--A'. - (Equivalently, you can use git reset --soft or git rebase -i.) - -2) Writing follow-up commits. Initial work is again in A, and after - review comments, you write a new commit B so your history looks - like O--A--B. When you upload the revised patch, you upload the - diff of O..B, not A..B; you always upload the full diff of what - you're proposing to change. - -The Rietveld patch uploader just takes arguments to "git diff", so -either of the above workflows work fine. If all you want to do is -upload a patch, you can use the upload.py provided by Rietveld with -arguments like this: - - upload.py --server server.com - -The first time you upload, it creates a new issue; for follow-ups on -the same issue, you need to provide the issue number: - - upload.py --server server.com --issue 1234 - -== git-cl to the rescue -git-cl simplifies the above in the following ways: - -1) "git cl config" puts a persistent --server setting in your .git/config. - -2) The first time you upload an issue, the issue number is associated with - the current *branch*. If you upload again, it will upload on the same - issue. (Note that this association is tied to a branch, not a commit, - which means you need a separate branch per review.) - -3) If your branch is "tracking" (in the "git checkout --track" sense) - another one (like origin/master), calls to "git cl upload" will - diff against that branch by default. (You can still pass arguments - to "git diff" on the command line, if necessary.) - -In the common case, this means that calling simply "git cl upload" -will always upload the correct diff to the correct place. - -== Patch series -The above is all you need to know for working on a single patch. - -Things get much more complicated when you have a series of commits -that you want to get reviewed. Say your history looks like -O--A--B--C. If you want to upload that as a single review, everything -works just as above. - -But what if you upload each of A, B, and C as separate reviews? -What if you then need to change A? - -1) One option is rewriting history: write a new commit A', then use - git rebase -i to insert that diff in as O--A--A'--B--C as well as - squash it. This is sometimes not possible if B and C have touched - some lines affected by A'. - -2) Another option, and the one espoused by software like topgit, is for - you to have separate branches for A, B, and C, and after writing A' - you merge it into each of those branches. (topgit automates this - merging process.) This is also what is recommended by git-cl, which - likes having different branch identifiers to hang the issue number - off of. Your history ends up looking like: - - O---A---B---C - \ \ \ - A'--B'--C' - - Which is ugly, but it accurately tracks the real history of your work, can - be thrown away at the end by committing A+A' as a single "squash" commit. - -In practice, this comes up pretty rarely. Suggestions for better workflows -are welcome. diff --git a/drover.py b/drover.py old mode 100644 new mode 100755 index 40d5d01ed..6077ada2f --- a/drover.py +++ b/drover.py @@ -1,3 +1,4 @@ +#!/usr/bin/python # Copyright (c) 2009 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. @@ -554,4 +555,4 @@ if __name__ == "__main__": option_parser.error("--merge requires a --branch") sys.exit(1) - sys.exit(main(options, args)) \ No newline at end of file + sys.exit(main(options, args)) diff --git a/gcl.py b/gcl.py index 8b1493190..1ed90519e 100755 --- a/gcl.py +++ b/gcl.py @@ -15,7 +15,7 @@ import string import subprocess import sys import tempfile -import upload +from third_party import upload import urllib2 import breakpad diff --git a/gclient.py b/gclient.py index 560badae1..df2085eb9 100755 --- a/gclient.py +++ b/gclient.py @@ -1,18 +1,7 @@ #!/usr/bin/python -# -# Copyright 2008 Google Inc. All Rights Reserved. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright (c) 2010 The Chromium Authors. All rights reserved. +# Use of this source code is governed by a BSD-style license that can be +# found in the LICENSE file. """A wrapper script to manage a set of client modules in different SCM. diff --git a/git-try b/git-try index 099ed5f8f..8cb807731 100755 --- a/git-try +++ b/git-try @@ -1,5 +1,5 @@ #!/usr/bin/python -# Copyright (c) 2009 The Chromium Authors. All rights reserved. +# Copyright (c) 2010 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Wrapper for trychange.py for git checkout.""" @@ -7,10 +7,7 @@ import logging import sys -try: - import breakpad -except ImportError: - pass +import breakpad from scm import GIT import trychange diff --git a/presubmit_canned_checks.py b/presubmit_canned_checks.py old mode 100755 new mode 100644 index af8b0d603..839fe1d7f --- a/presubmit_canned_checks.py +++ b/presubmit_canned_checks.py @@ -1,5 +1,4 @@ -#!/usr/bin/env python -# Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. +# Copyright (c) 2010 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. diff --git a/tests/README.gclient_test b/tests/README.gclient_test deleted file mode 100644 index 74194c753..000000000 --- a/tests/README.gclient_test +++ /dev/null @@ -1,6 +0,0 @@ -# Copyright 2008-2009, Google Inc. - -To run the gclient's unit tests, you need to checkout pymox and install it: -svn co http://pymox.googlecode.com/svn/trunk pymox -cd pymox -python setup.py install diff --git a/tests/gcl_unittest.py b/tests/gcl_unittest.py index e7ba59238..a08596623 100755 --- a/tests/gcl_unittest.py +++ b/tests/gcl_unittest.py @@ -1,14 +1,15 @@ #!/usr/bin/python -# Copyright (c) 2009 The Chromium Authors. All rights reserved. +# Copyright (c) 2010 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Unit tests for gcl.py.""" -# Local imports -import gcl +# Fixes include path. from super_mox import mox, SuperMoxTestBase +import gcl + class GclTestsBase(SuperMoxTestBase): """Setups and tear downs the mocks but doesn't test anything as-is.""" diff --git a/tests/gclient_scm_test.py b/tests/gclient_scm_test.py index 61146b4a4..0fa85b427 100755 --- a/tests/gclient_scm_test.py +++ b/tests/gclient_scm_test.py @@ -1,30 +1,21 @@ #!/usr/bin/python -# -# Copyright 2008-2009 Google Inc. All Rights Reserved. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright (c) 2010 The Chromium Authors. All rights reserved. +# Use of this source code is governed by a BSD-style license that can be +# found in the LICENSE file. """Unit tests for gclient_scm.py.""" -import os -import shutil -# Import it before super_mox to keep a valid reference. +# Import before super_mox to keep valid references. +from os import rename +from shutil import rmtree from subprocess import Popen, PIPE, STDOUT import tempfile +# Fixes include path. +from super_mox import mox, SuperMoxBaseTestBase + import gclient_scm from gclient_test import BaseTestCase as GCBaseTestCase -from super_mox import mox, SuperMoxBaseTestBase class BaseTestCase(GCBaseTestCase): @@ -373,7 +364,7 @@ from :3 def tearDown(self): SuperMoxBaseTestBase.tearDown(self) - shutil.rmtree(self.root_dir) + rmtree(self.root_dir) def testDir(self): members = [ @@ -503,7 +494,7 @@ from :3 self.assertEquals(scm.revinfo(options, (), None), '069c602044c5388d2d15c3f875b057c852003458') finally: - shutil.rmtree(root_dir) + rmtree(root_dir) def testUpdateUpdate(self): if not self.enabled: @@ -549,7 +540,7 @@ from :3 scm = gclient_scm.CreateSCM(url=self.url, root_dir=self.root_dir, relpath=self.relpath) git_path = gclient_scm.os.path.join(self.base_path, '.git') - os.rename(git_path, git_path + 'foo') + rename(git_path, git_path + 'foo') exception = \ '\n____ .\n' \ '\tPath is not a git repo. No .git dir.\n' \ diff --git a/tests/gclient_test.py b/tests/gclient_test.py index e21c20ae7..13e24ab09 100755 --- a/tests/gclient_test.py +++ b/tests/gclient_test.py @@ -1,28 +1,14 @@ #!/usr/bin/python -# -# Copyright 2008-2009 Google Inc. All Rights Reserved. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright (c) 2010 The Chromium Authors. All rights reserved. +# Use of this source code is governed by a BSD-style license that can be +# found in the LICENSE file. """Unit tests for gclient.py.""" -__author__ = 'stephen5.ng@gmail.com (Stephen Ng)' - -import __builtin__ -import StringIO +# Fixes include path. +from super_mox import mox, IsOneOf, SuperMoxTestBase import gclient -from super_mox import mox, IsOneOf, SuperMoxTestBase class BaseTestCase(SuperMoxTestBase): diff --git a/tests/gclient_utils_test.py b/tests/gclient_utils_test.py old mode 100644 new mode 100755 index 58864635d..fa1ee72e5 --- a/tests/gclient_utils_test.py +++ b/tests/gclient_utils_test.py @@ -1,14 +1,15 @@ #!/usr/bin/python -# Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. +# Copyright (c) 2010 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -import re import StringIO -import gclient_utils +# Fixes include path. from super_mox import SuperMoxTestBase +import gclient_utils + class GclientUtilsUnittest(SuperMoxTestBase): """General gclient_utils.py tests.""" @@ -82,7 +83,7 @@ class SubprocessCallAndFilterTestCase(SuperMoxTestBase): stdout=gclient_utils.subprocess.PIPE, stderr=gclient_utils.subprocess.STDOUT).AndReturn(kid) self.mox.ReplayAll() - compiled_pattern = re.compile(pattern) + compiled_pattern = gclient_utils.re.compile(pattern) line_list = [] capture_list = [] def FilterLines(line): diff --git a/tests/presubmit_unittest.py b/tests/presubmit_unittest.py index 91825c53e..b4737be8d 100755 --- a/tests/presubmit_unittest.py +++ b/tests/presubmit_unittest.py @@ -1,5 +1,5 @@ #!/usr/bin/python -# Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. +# Copyright (c) 2010 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. @@ -7,10 +7,12 @@ import StringIO +# Fixes include path. +from super_mox import mox, SuperMoxTestBase + import presubmit_support as presubmit # Shortcut. -from presubmit_support import presubmit_canned_checks -from super_mox import mox, SuperMoxTestBase +presubmit_canned_checks = presubmit.presubmit_canned_checks class PresubmitTestsBase(SuperMoxTestBase): diff --git a/tests/scm_unittest.py b/tests/scm_unittest.py index 3807e97d4..e5f8a64d8 100755 --- a/tests/scm_unittest.py +++ b/tests/scm_unittest.py @@ -1,16 +1,18 @@ #!/usr/bin/python -# Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. +# Copyright (c) 2010 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Unit tests for scm.py.""" -import shutil +from shutil import rmtree import tempfile +# Fixes include path. +from super_mox import mox, SuperMoxBaseTestBase + from gclient_test import BaseTestCase import scm -from super_mox import mox, SuperMoxBaseTestBase class BaseSCMTestCase(BaseTestCase): @@ -110,7 +112,7 @@ from :3 self.fake_root = self.Dir() def tearDown(self): - shutil.rmtree(self.root_dir) + rmtree(self.root_dir) SuperMoxBaseTestBase.tearDown(self) def testMembersChanged(self): diff --git a/tests/super_mox.py b/tests/super_mox.py index 4fb7962d5..bdd96a5c5 100644 --- a/tests/super_mox.py +++ b/tests/super_mox.py @@ -1,5 +1,5 @@ #!/usr/bin/python -# Copyright (c) 2009 The Chromium Authors. All rights reserved. +# Copyright (c) 2010 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. @@ -8,10 +8,13 @@ import __builtin__ import os import random +import shutil import string import subprocess import sys -from pymox import mox + +sys.path.append(os.path.dirname(os.path.dirname(__file__))) +from third_party.pymox import mox class IsOneOf(mox.Comparator): @@ -96,6 +99,7 @@ class SuperMoxTestBase(SuperMoxBaseTestBase): os_path_to_mock = ('abspath', 'exists', 'getsize', 'isdir', 'isfile', 'islink', 'ismount', 'lexists', 'realpath', 'samefile', 'walk') self.MockList(os.path, os_path_to_mock) + self.MockList(shutil, ('rmtree')) self.MockList(subprocess, ('call', 'Popen')) # Don't mock stderr since it confuses unittests. self.MockList(sys, ('stdin', 'stdout')) @@ -105,4 +109,7 @@ class SuperMoxTestBase(SuperMoxBaseTestBase): # Skip over items not present because of OS-specific implementation, # implemented only in later python version, etc. if hasattr(parent, item): - self.mox.StubOutWithMock(parent, item) + try: + self.mox.StubOutWithMock(parent, item) + except TypeError: + raise TypeError('Couldn\'t mock %s in %s' % (item, parent.__name__)) diff --git a/tests/trychange_unittest.py b/tests/trychange_unittest.py old mode 100644 new mode 100755 index ebd72b84a..8fc91857a --- a/tests/trychange_unittest.py +++ b/tests/trychange_unittest.py @@ -1,15 +1,14 @@ #!/usr/bin/python -# Copyright (c) 2009 The Chromium Authors. All rights reserved. +# Copyright (c) 2010 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Unit tests for trychange.py.""" -import optparse +# Fixes include path. +from super_mox import mox, SuperMoxTestBase -# Local imports import trychange -from super_mox import mox, SuperMoxTestBase class TryChangeTestsBase(SuperMoxTestBase): @@ -28,7 +27,7 @@ class TryChangeTestsBase(SuperMoxTestBase): self.mox.StubOutWithMock(trychange.scm.SVN, 'GetEmail') self.fake_root = self.Dir() self.expected_files = ['foo.txt', 'bar.txt'] - self.options = optparse.Values() + self.options = trychange.optparse.Values() self.options.files = self.expected_files self.options.diff = None self.options.name = None diff --git a/third_party/__init__.py b/third_party/__init__.py new file mode 100644 index 000000000..e591d71fa --- /dev/null +++ b/third_party/__init__.py @@ -0,0 +1,5 @@ +# Copyright (c) 2010 The Chromium Authors. All rights reserved. +# Use of this source code is governed by a BSD-style license that can be +# found in the LICENSE file. + +"""File to enable importing from third_party.""" diff --git a/tests/pymox/COPYING b/third_party/pymox/COPYING similarity index 100% rename from tests/pymox/COPYING rename to third_party/pymox/COPYING diff --git a/tests/pymox/MANIFEST.in b/third_party/pymox/MANIFEST.in similarity index 100% rename from tests/pymox/MANIFEST.in rename to third_party/pymox/MANIFEST.in diff --git a/tests/pymox/README b/third_party/pymox/README similarity index 100% rename from tests/pymox/README rename to third_party/pymox/README diff --git a/tests/pymox/__init__.py b/third_party/pymox/__init__.py similarity index 100% rename from tests/pymox/__init__.py rename to third_party/pymox/__init__.py diff --git a/tests/pymox/mox.py b/third_party/pymox/mox.py similarity index 100% rename from tests/pymox/mox.py rename to third_party/pymox/mox.py diff --git a/tests/pymox/mox_test.py b/third_party/pymox/mox_test.py similarity index 100% rename from tests/pymox/mox_test.py rename to third_party/pymox/mox_test.py diff --git a/tests/pymox/mox_test_helper.py b/third_party/pymox/mox_test_helper.py similarity index 100% rename from tests/pymox/mox_test_helper.py rename to third_party/pymox/mox_test_helper.py diff --git a/tests/pymox/setup.py b/third_party/pymox/setup.py similarity index 100% rename from tests/pymox/setup.py rename to third_party/pymox/setup.py diff --git a/tests/pymox/stubout.py b/third_party/pymox/stubout.py similarity index 100% rename from tests/pymox/stubout.py rename to third_party/pymox/stubout.py diff --git a/tests/pymox/stubout_test.py b/third_party/pymox/stubout_test.py similarity index 100% rename from tests/pymox/stubout_test.py rename to third_party/pymox/stubout_test.py diff --git a/tests/pymox/stubout_testee.py b/third_party/pymox/stubout_testee.py similarity index 100% rename from tests/pymox/stubout_testee.py rename to third_party/pymox/stubout_testee.py diff --git a/upload.py b/third_party/upload.py similarity index 100% rename from upload.py rename to third_party/upload.py