Search in sources :

Example 1 with SnapshotDaoImpl

use of com.cloud.storage.dao.SnapshotDaoImpl in project CloudStack-archive by CloudStack-extras.

the class SnapshotDaoTest method testListBy.

public void testListBy() {
    SnapshotDaoImpl dao = ComponentLocator.inject(SnapshotDaoImpl.class);
    List<SnapshotVO> snapshots = dao.listByInstanceId(3, Snapshot.Status.BackedUp);
    for (SnapshotVO snapshot : snapshots) {
        Assert.assertTrue(snapshot.getStatus() == Snapshot.Status.BackedUp);
    }
}
Also used : SnapshotVO(com.cloud.storage.SnapshotVO) SnapshotDaoImpl(com.cloud.storage.dao.SnapshotDaoImpl)

Aggregations

SnapshotVO (com.cloud.storage.SnapshotVO)1 SnapshotDaoImpl (com.cloud.storage.dao.SnapshotDaoImpl)1