Loading tests/functional/com/android/documentsui/FileCopyUiTest.java +5 −7 Original line number Diff line number Diff line Loading @@ -41,15 +41,13 @@ import com.android.documentsui.base.State; import com.android.documentsui.files.FilesActivity; import com.android.documentsui.services.TestNotificationService; import org.apache.commons.compress.archivers.ArchiveEntry; import org.apache.commons.compress.archivers.zip.ZipArchiveEntry; import org.apache.commons.compress.archivers.zip.ZipArchiveInputStream; import java.util.concurrent.CountDownLatch; import java.util.concurrent.TimeUnit; import java.util.HashMap; import java.util.List; import java.util.Map; import java.util.zip.ZipEntry; import java.util.zip.ZipInputStream; /** * This class test the below points Loading Loading @@ -249,12 +247,12 @@ public class FileCopyUiTest extends ActivityTest<FilesActivity> { private void loadImageFromResources(Uri root, DocumentsProviderHelper helper, int resId, Resources res) throws Exception { ZipArchiveInputStream in = null; ZipInputStream in = null; int read = 0; int count = 0; try { in = new ZipArchiveInputStream(res.openRawResource(resId)); ArchiveEntry archiveEntry = null; in = new ZipInputStream(res.openRawResource(resId)); ZipEntry archiveEntry = null; while ((archiveEntry = in.getNextEntry()) != null && (count++ < TARGET_COUNT)) { String fileName = archiveEntry.getName(); Uri uri = helper.createDocument(root, "image/png", fileName); Loading Loading
tests/functional/com/android/documentsui/FileCopyUiTest.java +5 −7 Original line number Diff line number Diff line Loading @@ -41,15 +41,13 @@ import com.android.documentsui.base.State; import com.android.documentsui.files.FilesActivity; import com.android.documentsui.services.TestNotificationService; import org.apache.commons.compress.archivers.ArchiveEntry; import org.apache.commons.compress.archivers.zip.ZipArchiveEntry; import org.apache.commons.compress.archivers.zip.ZipArchiveInputStream; import java.util.concurrent.CountDownLatch; import java.util.concurrent.TimeUnit; import java.util.HashMap; import java.util.List; import java.util.Map; import java.util.zip.ZipEntry; import java.util.zip.ZipInputStream; /** * This class test the below points Loading Loading @@ -249,12 +247,12 @@ public class FileCopyUiTest extends ActivityTest<FilesActivity> { private void loadImageFromResources(Uri root, DocumentsProviderHelper helper, int resId, Resources res) throws Exception { ZipArchiveInputStream in = null; ZipInputStream in = null; int read = 0; int count = 0; try { in = new ZipArchiveInputStream(res.openRawResource(resId)); ArchiveEntry archiveEntry = null; in = new ZipInputStream(res.openRawResource(resId)); ZipEntry archiveEntry = null; while ((archiveEntry = in.getNextEntry()) != null && (count++ < TARGET_COUNT)) { String fileName = archiveEntry.getName(); Uri uri = helper.createDocument(root, "image/png", fileName); Loading