summaryrefslogtreecommitdiff
path: root/src/main/java/com/android/vts/servlet/ShowPlanRunServlet.java
diff options
context:
space:
mode:
authorYoung Gyu Park <younggyu@google.com>2018-08-14 11:20:10 +0900
committerYoung Gyu Park <younggyu@google.com>2018-08-14 11:20:10 +0900
commit9bad56729ad45d30d2c1cf452a7915c6f1eac5a7 (patch)
tree21526c6014aa103d73f831b9a69437906523b2fc /src/main/java/com/android/vts/servlet/ShowPlanRunServlet.java
parentc4798bc4cd5ca6734b5918cef141159c4dfa6876 (diff)
downloaddashboard-9bad56729ad45d30d2c1cf452a7915c6f1eac5a7.tar.gz
Updating servlet according to the change of entity
Test: go/vts-web-staging Bug: 111481322 Change-Id: I8d10727045ce71f434b257deea5214c40795dc5b
Diffstat (limited to 'src/main/java/com/android/vts/servlet/ShowPlanRunServlet.java')
-rw-r--r--src/main/java/com/android/vts/servlet/ShowPlanRunServlet.java12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/main/java/com/android/vts/servlet/ShowPlanRunServlet.java b/src/main/java/com/android/vts/servlet/ShowPlanRunServlet.java
index bce89fc..9138a90 100644
--- a/src/main/java/com/android/vts/servlet/ShowPlanRunServlet.java
+++ b/src/main/java/com/android/vts/servlet/ShowPlanRunServlet.java
@@ -98,18 +98,24 @@ public class ShowPlanRunServlet extends BaseServlet {
long startTime = 0;
long endTime = 0;
long moduleCount = 0;
+ long totalApiCount = 0L;
+ long totalCoveredApiCount = 0L;
try {
Entity testPlanRunEntity = datastore.get(planRunKey);
TestPlanRunEntity testPlanRun = TestPlanRunEntity.fromEntity(testPlanRunEntity);
- Map<Key, Entity> testRuns = datastore.get(testPlanRun.getTestRuns());
+ Map<Key, Entity> testRuns = datastore.get(testPlanRun.getOldTestRuns());
testBuildId = testPlanRun.getTestBuildId();
passCount = (int) testPlanRun.getPassCount();
failCount = (int) testPlanRun.getFailCount();
+ totalApiCount = testPlanRun.getTotalApiCount();
+ logger.log(Level.INFO, "totalApiCount => " + totalApiCount);
+ totalCoveredApiCount = testPlanRun.getCoveredApiCount();
+ logger.log(Level.INFO, "totalCoveredApiCount => " + totalCoveredApiCount);
startTime = testPlanRun.getStartTimestamp();
endTime = testPlanRun.getEndTimestamp();
moduleCount = testPlanRun.getTestRuns().size();
- for (Key key : testPlanRun.getTestRuns()) {
+ for (Key key : testPlanRun.getOldTestRuns()) {
if (!testRuns.containsKey(key)) continue;
TestRunEntity testRunEntity = TestRunEntity.fromEntity(testRuns.get(key));
if (testRunEntity == null) continue;
@@ -150,6 +156,8 @@ public class ShowPlanRunServlet extends BaseServlet {
request.setAttribute("moduleCount", new Gson().toJson(moduleCount));
request.setAttribute("passingTestCaseCount", new Gson().toJson(passCount));
request.setAttribute("failingTestCaseCount", new Gson().toJson(failCount));
+ request.setAttribute("totalApiCount", totalApiCount);
+ request.setAttribute("totalCoveredApiCount", totalCoveredApiCount);
// data for pie chart
request.setAttribute("topBuildResultCounts", new Gson().toJson(topBuildResultCounts));