Merge lp:~dobey/ubuntuone-storage-protocol/update-4-0 into lp:ubuntuone-storage-protocol/stable-4-0

Proposed by dobey
Status: Merged
Approved by: dobey
Approved revision: no longer in the source branch.
Merged at revision: 149
Proposed branch: lp:~dobey/ubuntuone-storage-protocol/update-4-0
Merge into: lp:ubuntuone-storage-protocol/stable-4-0
Diff against target: 103 lines (+40/-4)
6 files modified
data/ValiCert_Class_2_VA.pem (+18/-0)
setup.py (+1/-0)
tests/test_context.py (+15/-0)
tests/test_dircontent.py (+1/-1)
ubuntuone/storageprotocol/client.py (+2/-2)
ubuntuone/storageprotocol/context.py (+3/-1)
To merge this branch: bzr merge lp:~dobey/ubuntuone-storage-protocol/update-4-0
Reviewer Review Type Date Requested Status
Roberto Alsina (community) Approve
Review via email: mp+111929@code.launchpad.net

Commit message

[Alejandro Cura]

    - Add the ValiCert certificate to the custom certificates (LP: #882062).

[Rodney Dawes]

    - Patch get_certificates to use the uninstalled certificates when testing.

To post a comment you must log in.
Revision history for this message
Roberto Alsina (ralsina) :
review: Approve
Revision history for this message
Ubuntu One Auto Pilot (otto-pilot) wrote :
Download full text (38.1 KiB)

The attempt to merge lp:~dobey/ubuntuone-storage-protocol/update-4-0 into lp:ubuntuone-storage-protocol/stable-4-0 failed. Below is the output from the failed tests.

running build
running build_py
creating build
creating build/lib.linux-x86_64-2.7
creating build/lib.linux-x86_64-2.7/ubuntuone
copying ubuntuone/__init__.py -> build/lib.linux-x86_64-2.7/ubuntuone
creating build/lib.linux-x86_64-2.7/ubuntuone/storageprotocol
copying ubuntuone/storageprotocol/content_hash.py -> build/lib.linux-x86_64-2.7/ubuntuone/storageprotocol
copying ubuntuone/storageprotocol/delta.py -> build/lib.linux-x86_64-2.7/ubuntuone/storageprotocol
copying ubuntuone/storageprotocol/dircontent_pb2.py -> build/lib.linux-x86_64-2.7/ubuntuone/storageprotocol
copying ubuntuone/storageprotocol/protocol_pb2.py -> build/lib.linux-x86_64-2.7/ubuntuone/storageprotocol
copying ubuntuone/storageprotocol/proxy_tunnel.py -> build/lib.linux-x86_64-2.7/ubuntuone/storageprotocol
copying ubuntuone/storageprotocol/dircontent.py -> build/lib.linux-x86_64-2.7/ubuntuone/storageprotocol
copying ubuntuone/storageprotocol/volumes.py -> build/lib.linux-x86_64-2.7/ubuntuone/storageprotocol
copying ubuntuone/storageprotocol/client.py -> build/lib.linux-x86_64-2.7/ubuntuone/storageprotocol
copying ubuntuone/storageprotocol/request.py -> build/lib.linux-x86_64-2.7/ubuntuone/storageprotocol
copying ubuntuone/storageprotocol/__init__.py -> build/lib.linux-x86_64-2.7/ubuntuone/storageprotocol
copying ubuntuone/storageprotocol/errors.py -> build/lib.linux-x86_64-2.7/ubuntuone/storageprotocol
copying ubuntuone/storageprotocol/sharersp.py -> build/lib.linux-x86_64-2.7/ubuntuone/storageprotocol
copying ubuntuone/storageprotocol/validators.py -> build/lib.linux-x86_64-2.7/ubuntuone/storageprotocol
copying ubuntuone/storageprotocol/context.py -> build/lib.linux-x86_64-2.7/ubuntuone/storageprotocol
copying ubuntuone/storageprotocol/utils.py -> build/lib.linux-x86_64-2.7/ubuntuone/storageprotocol
tests.test_delta_info
  DeltaTestCase
    test_correct_attributes ... [OK]
    test_is_equal ... [OK]
    test_parent_id_None ... [OK]
    test_root_share_id ... [OK]
tests.test_query
  TestQuery10
    test_query_many ... [OK]
  TestQuery1000
    test_query_many ... [OK]
tests.test_hashes
  ContentHashingTests
    test_content_hash ... [OK]
    test_hashing_content_once ... [OK]
    test_hashing_content_upadting ... [OK]
    test_hashing_empty ... [OK]
  FactoriesTest
    test_content_hash_factory ... [OK]
    test_content_hash_method ... [OK]
    test_content_hash_method_name ... [OK]
    test_magic_hash_factory ... ...

149. By dobey

[Alejandro Cura]

    - Add the ValiCert certificate to the custom certificates (LP: #882062).

[Rodney Dawes]

    - Patch get_certificates to use the uninstalled certificates when testing.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== added file 'data/ValiCert_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mNr0HZDzTu
20+IYEZoDJJKPTEjlbVUjP9UNV+mWwD5MlM/Mtsq2azSiGM5bUMMj4QssxsodyamEwC
21+W/POuZ6lcg5Ktz885hZo+L7tdEy8W9ViH0Pd
22+-----END CERTIFICATE-----
23
24=== modified file 'setup.py'
25--- setup.py 2012-06-08 20:15:59 +0000
26+++ setup.py 2012-06-26 02:07:19 +0000
27@@ -76,6 +76,7 @@
28 extra_path='ubuntuone-storage-protocol',
29 data_files=[(ssl_cert_location,
30 ['data/UbuntuOne-Go_Daddy_CA.pem',
31+ 'data/ValiCert_Class_2_VA.pem',
32 'data/UbuntuOne-Go_Daddy_Class_2_CA.pem'])],
33
34 cmdclass={
35
36=== modified file 'tests/test_context.py'
37--- tests/test_context.py 2012-06-08 19:18:15 +0000
38+++ tests/test_context.py 2012-06-26 02:07:19 +0000
39@@ -117,6 +117,21 @@
40 """Tests for the context.get_ssl_context function."""
41
42 @defer.inlineCallbacks
43+ def setUp(self):
44+ yield super(SSLContextTestCase, self).setUp()
45+ self.patch(context, "get_certificates", self.get_certificates)
46+
47+ def get_certificates(self):
48+ """Get the uninstalled certificates, for testing."""
49+ ca_1 = ssl.Certificate.loadPEM(file(os.path.abspath(os.path.join(
50+ os.pardir, os.pardir, 'data',
51+ 'UbuntuOne-Go_Daddy_Class_2_CA.pem')), 'r').read())
52+ ca_2 = ssl.Certificate.loadPEM(file(os.path.abspath(os.path.join(
53+ os.pardir, os.pardir, 'data',
54+ 'UbuntuOne-Go_Daddy_CA.pem')), 'r').read())
55+ return [ca_1.original, ca_2.original]
56+
57+ @defer.inlineCallbacks
58 def verify_context(self, server_context, client_context):
59 """Verify a client context with a given server context."""
60 site = server.Site(FakeResource())
61
62=== modified file 'tests/test_dircontent.py'
63--- tests/test_dircontent.py 2012-03-29 20:28:09 +0000
64+++ tests/test_dircontent.py 2012-06-26 02:07:19 +0000
65@@ -96,7 +96,7 @@
66 self.assert_(a == a)
67 self.assert_(a == a2)
68 self.assert_(a != b)
69- self.assert_(a != None)
70+ self.assert_(a is not None)
71
72 def testEntryName(self):
73 """Verify that name and utf8_name are encoded and decoded properly."""
74
75=== modified file 'ubuntuone/storageprotocol/client.py'
76--- ubuntuone/storageprotocol/client.py 2012-03-29 20:28:09 +0000
77+++ ubuntuone/storageprotocol/client.py 2012-06-26 02:07:19 +0000
78@@ -1730,8 +1730,8 @@
79 """
80 delayed_call = getattr(self, call_id)
81 # check if we already have a DelayedCall running
82- if delayed_call is None or (not delayed_call.active() \
83- and delayed_call.cancelled):
84+ if delayed_call is None or (not delayed_call.active()
85+ and delayed_call.cancelled):
86 return self.callLater(period, func)
87 return delayed_call
88
89
90=== modified file 'ubuntuone/storageprotocol/context.py'
91--- ubuntuone/storageprotocol/context.py 2012-06-08 19:18:15 +0000
92+++ ubuntuone/storageprotocol/context.py 2012-06-26 02:07:19 +0000
93@@ -92,7 +92,9 @@
94 'UbuntuOne-Go_Daddy_Class_2_CA.pem'), 'r').read())
95 ca_file_2 = ssl.Certificate.loadPEM(file(os.path.join(ssl_cert_location,
96 'UbuntuOne-Go_Daddy_CA.pem'), 'r').read())
97- return [ca_file.original, ca_file_2.original]
98+ ca_file_3 = ssl.Certificate.loadPEM(file(os.path.join(ssl_cert_location,
99+ 'ValiCert_Class_2_VA.pem'), 'r').read())
100+ return [ca_file.original, ca_file_2.original, ca_file_3.original]
101
102
103 def get_ssl_context(no_verify, hostname=None):

Subscribers

People subscribed via source and target branches

to all changes: