Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(290)

Unified Diff: appengine/findit/waterfall/test/buildbot_test.py

Issue 1149743002: [Findit] Use step level analysis to exclude flaky test failures. (Closed) Base URL: https://chromium.googlesource.com/infra/infra.git@master
Patch Set: Use cStringIO to pull the reliable test failures. Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: appengine/findit/waterfall/test/buildbot_test.py
diff --git a/appengine/findit/waterfall/test/buildbot_test.py b/appengine/findit/waterfall/test/buildbot_test.py
index 99b8c559c0a42ee3c9fd821394e5d4faf5aee5d1..fad8e3b3c2be75502cfa202bfc7cbc6a338e2af7 100644
--- a/appengine/findit/waterfall/test/buildbot_test.py
+++ b/appengine/findit/waterfall/test/buildbot_test.py
@@ -5,6 +5,10 @@
from datetime import datetime
import os
import unittest
stgao 2015/05/22 01:30:37 Unused now?
+from testing_utils import testing
stgao 2015/05/22 01:30:37 Why APIs from unittest are not enough?
chanli 2015/05/22 18:43:27 I don't quite remember, but I think back then I ne
+
+import cloudstorage as gcs
+import gzip
stgao 2015/05/22 01:30:37 style: order and category still not fixed.
from common.retry_http_client import RetryHttpClient
from waterfall import buildbot
@@ -26,7 +30,7 @@ class DummyHttpClient(RetryHttpClient):
return self.status_code, self.response_content
-class BuildBotTest(unittest.TestCase):
+class BuildBotTest(testing.AppengineTestCase):
def testGetMasternameFromUrl(self):
cases = {
None: None,
@@ -120,6 +124,19 @@ class BuildBotTest(unittest.TestCase):
buildbot.CreateStdioLogUrl(
master_name, builder_name, build_number, step_name))
+ def testCreateGtestResultPath(self):
+ master_name = 'a'
+ builder_name = 'Win7 Tests (1)'
+ build_number = 123
+ step_name = '[trigger] abc_tests'
+ expected_stdio_log_url = ('/chrome-gtest-results/buildbot/a/Win7 Tests '
+ '(1)/123/[trigger] abc_tests.json.gz')
+
+ self.assertEqual(
+ expected_stdio_log_url,
+ buildbot.CreateGtestResultPath(
+ master_name, builder_name, build_number, step_name))
+
def testGetBuildDataFromArchiveSuccess(self):
master_name = 'a'
builder_name = 'b c'

Powered by Google App Engine
This is Rietveld 408576698