[Openstack] Testing SSL?

Ask Solem ask at celeryproject.org
Thu Jan 5 15:12:27 UTC 2012


On 3 Jan 2012, at 12:20, Joshua Harlow wrote:

> For a submission I am doing for kombu enabling SSL,
> the code changes are mainly passing config down through
> kombu but I was wondering if there is a method (smoke test),
> unit test (does that make sense?) for ensuring that SSL is
> actually working as suggested.

A unit test would make sense, e.g. for the amqplib transport
you could mock the kombu.transports.pyamqplib.Connection object
and just test that the correct values are being passed to it.

> For this kombu change would it make sense to test that the
> kombu library passes the SSL config all the way through
> or is this more of testing kombu (which openstack doesn't
> seem like it should be getting in the business of)?

> This seems like a similar question that could be asked
> for other SSL changes others are doing, are they adding
> tests (smoke or unit) that ensure SSL got turned on or
> are they relying on the underlying implementation (ie apache,
> rabbitmq, kombu...) and just making sure the correct config
> is passed to that implementation?

Pedantically speaking, if you tested the actual implementation
it wouldn't be a unit test.

It definitely belongs in Kombu as a unit test, 
Kombu also has a functional test suite in the funtests/
directory, which could test that SSL is actually enabled in RabbitMQ.

You could add it to your own test suites as well,
but then it may be easier to run Kombu's
test suite as part of your CI or integrational processes.


-- 
Ask Solem
Staff Engineer, RabbitMQ, VMware
twitter.com/asksol | +44 (0)7713357179





-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 495 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.openstack.org/pipermail/openstack/attachments/20120105/0df3532c/attachment.sig>


More information about the Openstack mailing list