use of com.google.firebase.firestore.bundle.BundleSerializer in project firebase-android-sdk by firebase.
the class SpecTestCase method doLoadBundle.
private void doLoadBundle(String json) throws Exception {
BundleReader bundleReader = new BundleReader(new BundleSerializer(new RemoteSerializer(databaseInfo.getDatabaseId())), new ByteArrayInputStream(json.getBytes(StandardCharsets.UTF_8)));
LoadBundleTask bundleTask = new LoadBundleTask();
queue.runSync(() -> {
syncEngine.loadBundle(bundleReader, bundleTask);
bundleTask.addOnFailureListener(e -> log("Loading bundle failed with " + e));
});
assertTrue(bundleTask.isSuccessful());
}
Aggregations