summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorandroid-build-team Robot <android-build-team-robot@google.com>2020-05-19 01:08:04 +0000
committerandroid-build-team Robot <android-build-team-robot@google.com>2020-05-19 01:08:04 +0000
commit75c1823a6af394f16376615b88f935f547ef598d (patch)
tree20083593236e4c43a7cea4d2798b7f4346ca3218
parent145c76731153305b6a895854b194ec845f83714d (diff)
parentfea03d8cc0c43f6a13ce78e7cf66d9f061a023a8 (diff)
downloadloganalysis-75c1823a6af394f16376615b88f935f547ef598d.tar.gz
Snap for 6507440 from fea03d8cc0c43f6a13ce78e7cf66d9f061a023a8 to rvc-release
Change-Id: Ie007f58e21117bdf0937a6178c8d933aa3407743
-rw-r--r--OWNERS1
-rw-r--r--tests/src/com/android/loganalysis/parser/BugreportParserFuncTest.java12
-rw-r--r--tests/src/com/android/loganalysis/parser/LogcatParserFuncTest.java13
-rw-r--r--tests/src/com/android/loganalysis/parser/MonkeyLogParserFuncTest.java12
4 files changed, 7 insertions, 31 deletions
diff --git a/OWNERS b/OWNERS
index 90c5d36..6b17500 100644
--- a/OWNERS
+++ b/OWNERS
@@ -4,4 +4,3 @@ guangzhu@google.com
jdesprez@google.com
mrosenfeld@google.com
siniavine@google.com
-tobiast@google.com
diff --git a/tests/src/com/android/loganalysis/parser/BugreportParserFuncTest.java b/tests/src/com/android/loganalysis/parser/BugreportParserFuncTest.java
index b759e98..802c5c0 100644
--- a/tests/src/com/android/loganalysis/parser/BugreportParserFuncTest.java
+++ b/tests/src/com/android/loganalysis/parser/BugreportParserFuncTest.java
@@ -20,7 +20,6 @@ import com.android.loganalysis.item.BugreportItem;
import junit.framework.TestCase;
import java.io.BufferedReader;
-import java.io.FileNotFoundException;
import java.io.FileReader;
import java.io.IOException;
@@ -36,21 +35,14 @@ public class BugreportParserFuncTest extends TestCase {
* assist a developer in checking why a given bugreport file might not be parsed correctly by
* Brillopad.
*/
- public void testParse() {
- BufferedReader bugreportReader = null;
- try {
- bugreportReader = new BufferedReader(new FileReader(BUGREPORT_PATH));
- } catch (FileNotFoundException e) {
- fail(String.format("File not found at %s", BUGREPORT_PATH));
- }
+ public void testParse() throws Exception {
+ BufferedReader bugreportReader = new BufferedReader(new FileReader(BUGREPORT_PATH));
BugreportItem bugreport = null;
try {
long start = System.currentTimeMillis();
bugreport = new BugreportParser().parse(bugreportReader);
long stop = System.currentTimeMillis();
System.out.println(String.format("Bugreport took %d ms to parse.", stop - start));
- } catch (IOException e) {
- fail(String.format("IOException: %s", e.toString()));
} finally {
if (bugreportReader != null) {
try {
diff --git a/tests/src/com/android/loganalysis/parser/LogcatParserFuncTest.java b/tests/src/com/android/loganalysis/parser/LogcatParserFuncTest.java
index 7d63b19..5c43b75 100644
--- a/tests/src/com/android/loganalysis/parser/LogcatParserFuncTest.java
+++ b/tests/src/com/android/loganalysis/parser/LogcatParserFuncTest.java
@@ -20,7 +20,6 @@ import com.android.loganalysis.item.LogcatItem;
import junit.framework.TestCase;
import java.io.BufferedReader;
-import java.io.FileNotFoundException;
import java.io.FileReader;
import java.io.IOException;
@@ -36,21 +35,15 @@ public class LogcatParserFuncTest extends TestCase {
* assist a developer in checking why a given logcat file might not be parsed correctly by
* Brillopad.
*/
- public void testParse() {
- BufferedReader logcatReader = null;
- try {
- logcatReader = new BufferedReader(new FileReader(LOGCAT_PATH));
- } catch (FileNotFoundException e) {
- fail(String.format("File not found at %s", LOGCAT_PATH));
- }
+ public void testParse() throws Exception {
+ BufferedReader logcatReader = new BufferedReader(new FileReader(LOGCAT_PATH));
+
LogcatItem logcat = null;
try {
long start = System.currentTimeMillis();
logcat = new LogcatParser().parse(logcatReader);
long stop = System.currentTimeMillis();
System.out.println(String.format("Logcat took %d ms to parse.", stop - start));
- } catch (IOException e) {
- fail(String.format("IOException: %s", e.toString()));
} finally {
if (logcatReader != null) {
try {
diff --git a/tests/src/com/android/loganalysis/parser/MonkeyLogParserFuncTest.java b/tests/src/com/android/loganalysis/parser/MonkeyLogParserFuncTest.java
index 58fcebe..d4dec36 100644
--- a/tests/src/com/android/loganalysis/parser/MonkeyLogParserFuncTest.java
+++ b/tests/src/com/android/loganalysis/parser/MonkeyLogParserFuncTest.java
@@ -23,7 +23,6 @@ import com.android.loganalysis.item.MonkeyLogItem.DroppedCategory;
import junit.framework.TestCase;
import java.io.BufferedReader;
-import java.io.FileNotFoundException;
import java.io.FileReader;
import java.io.IOException;
@@ -39,21 +38,14 @@ public class MonkeyLogParserFuncTest extends TestCase {
* assist a developer in checking why a given monkey log file might not be parsed correctly by
* Brillopad.
*/
- public void testParse() {
- BufferedReader monkeyLogReader = null;
- try {
- monkeyLogReader = new BufferedReader(new FileReader(MONKEY_LOG_PATH));
- } catch (FileNotFoundException e) {
- fail(String.format("File not found at %s", MONKEY_LOG_PATH));
- }
+ public void testParse() throws Exception {
+ BufferedReader monkeyLogReader = new BufferedReader(new FileReader(MONKEY_LOG_PATH));
MonkeyLogItem monkeyLog = null;
try {
long start = System.currentTimeMillis();
monkeyLog = new MonkeyLogParser().parse(monkeyLogReader);
long stop = System.currentTimeMillis();
System.out.println(String.format("Monkey log took %d ms to parse.", stop - start));
- } catch (IOException e) {
- fail(String.format("IOException: %s", e.toString()));
} finally {
if (monkeyLogReader != null) {
try {