Merge "Verify that blobstore quota limits are enforced." into rvc-dev am: 97109fe511

Change-Id: I530fc33c7c27738d9922a2d7e634600880dc058b
This commit is contained in:
Sudheer Shanka
2020-04-22 18:44:53 +00:00
committed by Automerger Merge Worker
2 changed files with 4 additions and 1 deletions

View File

@@ -77,7 +77,7 @@ public class DummyBlobData {
return mRandomSeed; return mRandomSeed;
} }
public Builder setFileSize(int fileSize) { public Builder setFileSize(long fileSize) {
mFileSize = fileSize; mFileSize = fileSize;
return this; return this;
} }

View File

@@ -34,6 +34,9 @@ import java.io.OutputStream;
public class Utils { public class Utils {
public static final int BUFFER_SIZE_BYTES = 16 * 1024; public static final int BUFFER_SIZE_BYTES = 16 * 1024;
public static final long KB_IN_BYTES = 1000;
public static final long MB_IN_BYTES = KB_IN_BYTES * 1000;
public static void copy(InputStream in, OutputStream out, long lengthBytes) public static void copy(InputStream in, OutputStream out, long lengthBytes)
throws IOException { throws IOException {
final byte[] buffer = new byte[BUFFER_SIZE_BYTES]; final byte[] buffer = new byte[BUFFER_SIZE_BYTES];