HPSS: Other test changes

Robert Collins robertc at robertcollins.net
Tue Apr 17 06:05:35 BST 2007


On Tue, 2007-04-17 at 13:23 +1000, Andrew Bennetts wrote:
> 
>                     'bzrlib.tests.test_store',
> -                   'bzrlib.tests.test_strace',
>                     'bzrlib.tests.test_subsume', 

-1 on this change.


+        if isinstance(self.branch_format, RemoteBranchFormat):
+            raise TestSkipped(
+                "RemoteBranches don't have 'control_files'.")

I'm not sure if this is appropriate: do we want a Skip? or is it just an
irrelevant test?

ANyhow, AIUI RemoteBranch *does* have control_files now. -1 on this
change.

+
+    ## >>>>>>>
+    # XXX:
+    # This will always add the tests for smart server transport,
regardless of
+    # the --transport option the user specified to 'bzr selftest'.
+    from bzrlib.smart.server import SmartTCPServer_for_testing,
ReadonlySmartTCPServer_for_testing
+    from bzrlib.remote import RemoteBzrDirFormat
+
+    # test the remote server behaviour using a MemoryTransport
+    smart_server_suite = TestSuite()
+    adapt_to_smart_server = BzrDirTestProviderAdapter(
+        MemoryServer,
+        SmartTCPServer_for_testing,
+        ReadonlySmartTCPServer_for_testing,
+        [(RemoteBzrDirFormat())])
+    adapt_modules(test_bzrdir_implementations,
+                  adapt_to_smart_server,
+                  TestLoader(),
+                  smart_server_suite)
+    result.addTests(smart_server_suite)
+    ## >>>>>>>
+

I think this can be cleaned up. The XXX and >>>>> markers aren't really
appropriate now.


     def test_smart_wsgi_app_uses_given_relpath(self):
+        # XXX XXX XXX update comment
         # The SmartWSGIApp should use the "bzrlib.relpath" field from
the
         # WSGI environ to clone from its backing transport to get a
specific
         # transport for this request.

The XXX should be done before merging.

Other than that, +1.

-Rob
-- 
GPG key available at: <http://www.robertcollins.net/keys.txt>.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20070417/4a5662b4/attachment.pgp 


More information about the bazaar mailing list