Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(106)

Issue 11971025: [sync] Divorce python sync test server chromiumsync.py from testserver.py (Closed)

Created:
7 years, 11 months ago by Raghu Simha
Modified:
7 years, 11 months ago
CC:
chromium-reviews, cbentzel+watch_chromium.org, akalin, Raghu Simha, darin-cc_chromium.org, pam+watch_chromium.org, haitaol1, tim (not reviewing), dyu1
Visibility:
Public.

Description

[sync] Divorce python sync test server chromiumsync.py from testserver.py Various chrome test suites use the infrastructure in net::LocalTestServer and net/tools/testserver.py to create local test server instances against which to run automated tests. Sync tests use reference implementations of sync and xmpp servers, which build on the testserver infrastructure in net/. In the past, the sync testserver was small enough that it made sense for it to be a part of the testserver in net/. This, however, resulted in an unwanted dependency from net/ onto sync/, due to the sync proto modules needed to run a python sync server. Now that the sync testserver has grown considerably in scope, it is time to separate it out from net/ while reusing base testserver code, and eliminate the dependency from net/ onto sync/. This work also provides us with the opportunity to remove a whole bunch of dead pyauto sync test code in chrome/test/functional. This patch does the following: - Moves the native class LocalSyncTestServer from net/test/ to sync/test/. - Moves chromiumsync{_test}.py and xmppserver{_test}.py from net/tools/testserver/ to sync/tools/testserver/. - Removes all sync server specific code from net/. - Adds a new sync_testserver.py runner script for the python sync test. - Moves some base classes from testserver.py to testserver_base.py so they can be reused by sync_testserver.py. - Audits all the python imports in testserver.py, testserver_base.py and sync_testserver.py to make sure there are no unnecessary / missing imports. - Adds a new run_sync_testserver runner executable to launch a sync testserver. - Removes a couple of static methods from LocalTestServer, that were being used by run_testserver, and refactors run_sync_testserver to use their non-static versions. - Adds the ability to run both chromiumsync_test.py and xmppserver_test.py from run_sync_testserver. - Fixes chromiumsync.py to undo / rectify some older changes that broke tests in chromiumsync_test.py. - Adds a new test target called test_support_sync_testserver to sync.gyp. - Removes the hacky dependency on sync_proto from net.gyp:net_test_support. - Updates various gyp files across chrome to use the new sync testserver target. - Audits dependencies of net_test_support, run_testserver, and the newly added targets. - Fixes the android chrome testserver spawner script to account for the above changes. - Removes all mentions of TYPE_SYNC from the pyauto TestServer shim. - Deletes all (deprecated) pyauto sync tests. (They had all become broken over time, gotten disabled, and were all redundant due to their equivalent sync integration tests.) - Removes all sync related pyauto hooks from TestingAutomationProvider, since they are no longer going to be used. - Takes care of a TODO in safe_browser_testserver.py to remove an unnecessary code block. Note: A majority of the bugs listed below are for individual pyauto sync tests. Deleting the sync pyauto test script fixes all these bugs in one fell swoop. TBR=mattm@chromium.org BUG=117559, 119403, 159731, 15016, 80329, 49378, 87642, 86949, 88679, 104227, 88593, 124913 TEST=run_testserver, run_sync_testserver, sync_integration_tests, sync_performance_tests. All chrome tests that use a testserver should continue to work. Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=177864

Patch Set 1 : #

Total comments: 1

Patch Set 2 : Self review #

Total comments: 4

Patch Set 3 : Address Philippe's comments. #

Total comments: 12

Patch Set 4 : Address Pawel's comments. #

Patch Set 5 : More cleanup of dead pyauto code. #

Total comments: 4

Patch Set 6 : Fix nits #

Patch Set 7 : Rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+941 lines, -4566 lines) Patch
M build/android/pylib/chrome_test_server_spawner.py View 1 2 3 4 5 3 chunks +16 lines, -10 lines 0 comments Download
M chrome/browser/automation/testing_automation_provider.h View 1 4 chunks +1 line, -41 lines 0 comments Download
M chrome/browser/automation/testing_automation_provider.cc View 1 4 chunks +1 line, -247 lines 0 comments Download
M chrome/browser/safe_browsing/safe_browsing_testserver.py View 1 2 chunks +1 line, -7 lines 0 comments Download
M chrome/browser/sync/test/integration/sync_test.h View 3 chunks +4 lines, -4 lines 0 comments Download
M chrome/chrome_tests.gypi View 1 2 3 4 5 6 4 chunks +4 lines, -3 lines 0 comments Download
M chrome/test/functional/PYAUTO_TESTS View 1 2 3 4 8 chunks +1 line, -22 lines 0 comments Download
M chrome/test/functional/infobars.py View 1 2 3 4 2 chunks +1 line, -17 lines 0 comments Download
D chrome/test/functional/sync.py View 1 chunk +0 lines, -158 lines 0 comments Download
M chrome/test/functional/test_utils.py View 1 2 3 4 2 chunks +1 line, -40 lines 0 comments Download
M chrome/test/pyautolib/pyauto.py View 1 4 chunks +1 line, -180 lines 0 comments Download
M chrome/test/pyautolib/pyautolib.i View 3 chunks +1 line, -10 lines 0 comments Download
M net/net.gyp View 1 2 3 4 5 6 5 chunks +4 lines, -9 lines 0 comments Download
M net/test/base_test_server.h View 2 chunks +1 line, -2 lines 0 comments Download
M net/test/base_test_server.cc View 2 chunks +1 line, -2 lines 0 comments Download
D net/test/local_sync_test_server.h View 1 chunk +0 lines, -42 lines 0 comments Download
D net/test/local_sync_test_server.cc View 1 chunk +0 lines, -41 lines 0 comments Download
M net/test/local_test_server.h View 1 2 3 2 chunks +3 lines, -12 lines 0 comments Download
M net/test/local_test_server.cc View 1 2 3 5 chunks +13 lines, -31 lines 0 comments Download
M net/test/remote_test_server.cc View 2 chunks +1 line, -3 lines 0 comments Download
M net/tools/testserver/OWNERS View 1 chunk +2 lines, -8 lines 0 comments Download
D net/tools/testserver/chromiumsync.py View 1 chunk +0 lines, -1371 lines 0 comments Download
D net/tools/testserver/chromiumsync_test.py View 1 chunk +0 lines, -655 lines 0 comments Download
M net/tools/testserver/run_testserver.cc View 1 2 3 6 chunks +5 lines, -74 lines 0 comments Download
M net/tools/testserver/testserver.py View 14 chunks +33 lines, -539 lines 0 comments Download
M net/tools/testserver/testserver_base.py View 7 chunks +113 lines, -2 lines 0 comments Download
D net/tools/testserver/xmppserver.py View 1 chunk +0 lines, -594 lines 0 comments Download
D net/tools/testserver/xmppserver_test.py View 1 chunk +0 lines, -421 lines 0 comments Download
M sync/sync.gyp View 3 chunks +44 lines, -1 line 0 comments Download
M sync/test/DEPS View 1 chunk +1 line, -0 lines 0 comments Download
A + sync/test/local_sync_test_server.h View 1 2 3 4 5 3 chunks +16 lines, -10 lines 0 comments Download
A sync/test/local_sync_test_server.cc View 1 2 3 1 chunk +92 lines, -0 lines 0 comments Download
A + sync/tools/testserver/DEPS View 1 chunk +1 line, -1 line 0 comments Download
A sync/tools/testserver/OWNERS View 1 chunk +3 lines, -0 lines 0 comments Download
A + sync/tools/testserver/chromiumsync.py View 4 chunks +5 lines, -6 lines 0 comments Download
A + sync/tools/testserver/chromiumsync_test.py View 1 chunk +1 line, -1 line 0 comments Download
A sync/tools/testserver/run_sync_testserver.cc View 1 2 3 1 chunk +121 lines, -0 lines 0 comments Download
A sync/tools/testserver/sync_testserver.py View 1 2 3 4 5 6 1 chunk +447 lines, -0 lines 0 comments Download
A + sync/tools/testserver/xmppserver.py View 1 chunk +1 line, -1 line 0 comments Download
A + sync/tools/testserver/xmppserver_test.py View 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 14 (0 generated)
Raghu Simha
Folks, please review. Fred/Tim: Overall review + OWNERS approval for changes under sync/. Pawel: Changes ...
7 years, 11 months ago (2013-01-17 04:15:02 UTC) #1
Raghu Simha
Anyone on the review list know how to add a presubmit check that runs a ...
7 years, 11 months ago (2013-01-17 09:08:25 UTC) #2
Raghu Simha
+mattm@ for changes to safe_browsing_testserver.py. Feel free to take a look at any other changes ...
7 years, 11 months ago (2013-01-17 09:40:08 UTC) #3
Philippe
Thanks Raghu. LGTM for build/android/ with 2 minor nits. Please wait for Tommy too. https://codereview.chromium.org/11971025/diff/15044/build/android/pylib/chrome_test_server_spawner.py ...
7 years, 11 months ago (2013-01-17 10:27:13 UTC) #4
Raghu Simha
Philippe's comments addressed. Others, please let me know what you think. https://codereview.chromium.org/11971025/diff/15044/build/android/pylib/chrome_test_server_spawner.py File build/android/pylib/chrome_test_server_spawner.py (right): ...
7 years, 11 months ago (2013-01-17 21:51:09 UTC) #5
Paweł Hajdan Jr.
Thank you very much for working on this! I like the change. Only a few ...
7 years, 11 months ago (2013-01-17 23:38:48 UTC) #6
Raghu Simha
Pawel, feedback addressed. PTAL. https://codereview.chromium.org/11971025/diff/15046/build/android/pylib/chrome_test_server_spawner.py File build/android/pylib/chrome_test_server_spawner.py (right): https://codereview.chromium.org/11971025/diff/15046/build/android/pylib/chrome_test_server_spawner.py#newcode211 build/android/pylib/chrome_test_server_spawner.py:211: # The sync testserver is ...
7 years, 11 months ago (2013-01-18 02:17:09 UTC) #7
Raghu Simha
+ananthak to approve all the dead code removal from chrome/test/functional. +dyu as an FYI.
7 years, 11 months ago (2013-01-18 02:44:17 UTC) #8
Raghu Simha
Since akalin is on sabbatical, and timsteele is out sick, adding zea as backup reviewer ...
7 years, 11 months ago (2013-01-18 02:59:55 UTC) #9
anantha
LGTM for pyauto/functional changes.
7 years, 11 months ago (2013-01-18 21:42:40 UTC) #10
nyquist
build/android LGTM
7 years, 11 months ago (2013-01-18 21:47:55 UTC) #11
Paweł Hajdan Jr.
LGTM with nits https://codereview.chromium.org/11971025/diff/55003/build/android/pylib/chrome_test_server_spawner.py File build/android/pylib/chrome_test_server_spawner.py (right): https://codereview.chromium.org/11971025/diff/55003/build/android/pylib/chrome_test_server_spawner.py#newcode212 build/android/pylib/chrome_test_server_spawner.py:212: if self.arguments['server-type'] is 'sync': nit: is ...
7 years, 11 months ago (2013-01-18 22:41:28 UTC) #12
Raghu Simha
Nits fixed. https://codereview.chromium.org/11971025/diff/55003/build/android/pylib/chrome_test_server_spawner.py File build/android/pylib/chrome_test_server_spawner.py (right): https://codereview.chromium.org/11971025/diff/55003/build/android/pylib/chrome_test_server_spawner.py#newcode212 build/android/pylib/chrome_test_server_spawner.py:212: if self.arguments['server-type'] is 'sync': On 2013/01/18 22:41:29, ...
7 years, 11 months ago (2013-01-18 22:49:01 UTC) #13
commit-bot: I haz the power
7 years, 11 months ago (2013-01-19 03:20:56 UTC) #14

Powered by Google App Engine
This is Rietveld 408576698