'Test revert to snapshot after extended'

@decorators.idempotent_id('4e8b0788-87fe-430d-be7a-444d7f8e0347')
def test_volume_revert_to_snapshot_after_extended(self):

    self.volumes_client.extend_volume(self.volume['id'], new_size=2)
    waiters.wait_for_volume_resource_status(self.volumes_client, self.volume['id'], 'available')
    self.volume_revert_client.revert_to_snapshot(self.volume, self.snapshot['id'])
    waiters.wait_for_volume_resource_status(self.volumes_client, self.volume['id'], 'available')
    waiters.wait_for_volume_resource_status(self.snapshots_client, self.snapshot['id'], 'available')
    volume = self.volumes_client.show_volume(self.volume['id'])['volume']
    self.assertEqual(2, volume['size'])
