Comment 2 for bug 1564596

Revision history for this message
Matt Riedemann (mriedem) wrote :

I did some digging in Tempest this morning and there is a volume snapshots compute API test:

https://github.com/openstack/tempest/blob/master/tempest/api/compute/volumes/test_volume_snapshots.py#L42

However, that's simply testing the nova API proxy to the cinder API to snapshot a volume, it's not actually attached to a server instance. And it's redundant with another Tempest test, so probably needs to be removed or rewritten to include a server.

There is the test_stamp_pattern scenario test which snapshots a volume-backed server, but it's currently being skipped (I'm working on unskipping it).

So I think we basically need to cleanup https://github.com/openstack/tempest/blob/master/tempest/api/compute/volumes/test_volume_snapshots.py#L42 or add another set of tests in there which do the following:

1. snapshot a volume-backed server that is active (default case)
2. snapshot a volume-backed server that is shutdown
3. snapshot a volume-backed server that is paused
4. snapshot a volume-backed server that is suspended

I could see most of that test code being common code in the module, with individual tests calling it and passing in or handling the pre-condition for the server state.