/**
 * 
 */
package org.javarosa.cases.util;

import java.io.IOException;

import org.javarosa.cases.model.Case;
import org.javarosa.cases.storage.CaseRmsUtility;
import org.javarosa.core.JavaRosaServiceProvider;
import org.javarosa.core.services.storage.utilities.IRecordStoreEnumeration;
import org.javarosa.core.services.storage.utilities.RecordStorageException;
import org.javarosa.core.util.externalizable.DeserializationException;

/**
 * @author Clayton Sims
 * @date May 18, 2009 
 *
 */
public class CaseRestorableTest {
	public static void test() {
		CaseRmsUtility utility = (CaseRmsUtility)JavaRosaServiceProvider.instance().getStorageManager().getRMSStorageProvider().getUtility(CaseRmsUtility.getUtilityName());
		for (IRecordStoreEnumeration en = utility.enumerateMetaData(); en.hasNextElement(); ) {
			Case c = new Case();
			try {
				utility.retrieveFromRMS(en.nextRecordId(), c);
				RestorableTestHarness.evaluateRestorable(c);
			} catch (Exception e) {
				e.printStackTrace();
				throw new RuntimeException("Case was busted!");
			}
		}
	}
}

@@ -48,39 +48,8 @@
 %0D%0A%0D%0A
-import java.io.IOException;%0D%0A%0D%0A
 impo
@@ -266,157 +266,8 @@
 on;%0D
-%0Aimport org.javarosa.core.services.storage.utilities.RecordStorageException;%0D%0Aimport org.javarosa.core.util.externalizable.DeserializationException;%0D
 %0A%0D%0A/

clean up imports