Commit 5084800d authored by Josip Sokcevic's avatar Josip Sokcevic Committed by LUCI CQ

Fix flaky testPreDepsHooks test

Our Windows CI machine may take longer than 10s to process hooks
resulting in an extra block of information being printed. This change
updates the affected test to handle both fast and slow cases.

R=gavinmak@google.com

Fixed: 1352364
Change-Id: I62edbe49c0efc16cfed2bc218220840120c81c0a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3867544
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
Reviewed-by: 's avatarGavin Mak <gavinmak@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
Auto-Submit: Josip Sokcevic <sokcevic@google.com>
parent 228fedfa
......@@ -378,7 +378,9 @@ class GClientSmokeGIT(gclient_smoketest_base.GClientSmokeBase):
'--revision', 'src@' + self.githash('repo_5', 2)],
expectation)
self.assertEqual('Cloning into ', out[0][1][:13])
self.assertEqual(2, len(out[1]), out[1])
# parseGClient may produce hook slowness warning, so we expect either 2 or 3
# blocks.
self.assertIn(len(out[1]), [2, 3], out[1])
self.assertEqual('pre-deps hook', out[1][1])
tree = self.mangle_git_tree(('repo_5@2', 'src'),
('repo_1@2', 'src/repo1'),
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment