[openstack-dev] [Metering][Ceilometer] Newbie question - running tests in dev env ...

Sandy Walsh sandy.walsh at RACKSPACE.COM
Mon Jan 21 16:09:33 UTC 2013


Little more info

ceilometer/storage/__init__.py seems to default to mongo vs MIM.

 34 STORAGE_OPTS = [
 35     cfg.StrOpt('database_connection',
 36                default='mongodb://localhost:27017/ceilometer',
 37                help='Database connection string',
 38                ),
 39 ]


Is there a specific .conf the tests should be using as opposed to adopting the config defaults? (didn't see one obvious)

-S



________________________________
From: Sandy Walsh [sandy.walsh at RACKSPACE.COM]
Sent: Monday, January 21, 2013 11:45 AM
To: OpenStack Development Mailing List
Subject: Re: [openstack-dev] [Metering][Ceilometer] Newbie question - running tests in dev env ...

Thanks Doug,

Sadly, no joy.

It's still looking for mongodb and installing libvirt-bin makes no difference.

http://paste.openstack.org/show/29683/

Thoughts?

-S


________________________________
From: Doug Hellmann [doug.hellmann at dreamhost.com]
Sent: Thursday, January 17, 2013 4:47 PM
To: OpenStack Development Mailing List
Subject: Re: [openstack-dev] [Metering][Ceilometer] Newbie question - running tests in dev env ...



On Thu, Jan 17, 2013 at 2:15 PM, Sandy Walsh <sandy.walsh at rackspace.com<mailto:sandy.walsh at rackspace.com>> wrote:
Hey y'all,

Sorry for the post, but the IRC channel was dead.

I'm trying to set up a dev env for CM (sans devstack) and trying to get the tests running but they're blowing up for me left and right ... are they meant to run clean currently or is this a known issue? Are there any docs for getting a CM dev environment set up?

It looks like an upstream package that we depend on did a code reorg and since we're pointing at tip that broke us. I've got a code review to fix it up now at https://review.openstack.org/#/c/19969/

That issue is only related to a few of the API tests, though, so if you're seeing other failures post a traceback or two and I'll see if I can offer any suggestions.


There seems to be assumptions in there of a functioning mongodb and kvm ... are these not faked out for tests? Do I need to have a running mongo and kvm on my dev env (even if I'm not using these drivers)?

Although it is possible to test against a live mongo instance, the tests should default to using MIM (an in-memory version of Mongo created for tests). The tox configuration should set that up for you.

For kvm, you at least need libvirt installed. I'm pretty sure we have all of the tests mocking out the actual calls, though.


And what's the difference between ./ceilometer/ceilometer/tests/* and ./ceilometer/tests/*

The code in ceilometer.tests is support code for the actual tests. Because of the nose configuration, it's easier to import it from there in the tests that need it.

Doug


Any pointers would be great.

Thanks,
Sandy

_______________________________________________
OpenStack-dev mailing list
OpenStack-dev at lists.openstack.org<mailto:OpenStack-dev at lists.openstack.org>
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20130121/2e60b9df/attachment.html>


More information about the OpenStack-dev mailing list