New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 878926 link

Starred by 1 user

Issue metadata

Status: Assigned
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 2
Type: Bug



Sign in to add a comment

[Findit] Unit test failures

Project Member Reported by lijeffrey@chromium.org, Aug 29

Issue description

It seems unit tests may not always be cleaned up correctly. For example, when running "test.py test appengine/findit --jobs=1" to run in single-threaded mode, several tests fail intermittently:

ExtractCompileSignalTest.testFailedToGetFailureLog
ExtractTestSignalTest.testExtractSignalsForTestFailureNoFailureLog
ExtractTestSignalTest.testExtractSignalsForTestFailureNoTestResult
ExtractTestSignalTest.testGetSignalFromStepLog
DetectCQFalseRejectionFlakesTest.testOneFlakeOccurrence
DetectCQFalseRejectionFlakesTest.testParameterizedGtestFlakeOccurrences
BuildFailureAnalysisTest.testGetHeuristicSuspectedCLsNoAnalysis
TryJobTest.testGetCurrentTryJobIDNoTryJobData
IssueTrackingServiceTest.testHasNoFlakeAndFoundAnExistingOpenIssue
IssueTrackingServiceTest.testHasNoFlakeAndNoExistingOpenIssue

One thing many of these tests have in common is reads/writes to ndb using the same keys, e.g. master/builder/build number combinations
 
Project Member

Comment 1 by bugdroid1@chromium.org, Aug 29

The following revision refers to this bug:
  https://chromium.googlesource.com/infra/infra/+/224bd74c485bf834115efff900bc55871fdf1972

commit 224bd74c485bf834115efff900bc55871fdf1972
Author: Jeffrey Li <lijeffrey@chromium.org>
Date: Wed Aug 29 22:18:19 2018

[Findit] Flake Detection - Flaky Unit Test Workaround

Some unit tests are flaky depending on thread execution mode, possibly due
to the testing environment's datastore not being cleaned up properly between
tests within the same suite.

This CL is a simple workaround for some of the offending tests to write
different entities to the test datastore to avoid conflicts. The others in
the linked bug are not addressed.

Change-Id: I5a2ffc4250310fd2b86ed9d884cc470a3fbb2451
Bug: 878926
Reviewed-on: https://chromium-review.googlesource.com/1195943
Commit-Queue: Jeffrey Li <lijeffrey@chromium.org>
Reviewed-by: Shuotao Gao <stgao@chromium.org>
Cr-Commit-Position: refs/heads/master@{#17295}
[modify] https://crrev.com/224bd74c485bf834115efff900bc55871fdf1972/appengine/findit/services/test/issue_tracking_service_test.py

Owner: st...@chromium.org
Status: Assigned (was: Available)

Sign in to add a comment