Skip to content

Commit

Permalink
Mark Facebook CTL tests as pending when network is too slow (#1361)
Browse files Browse the repository at this point in the history
Occasionally the network will be too slow on the GitHub CI runner for
any Facebook requests to be made within 15 seconds. When that happens,
let's mark the tests as skipped (pending) instead of failing (or
passing).
  • Loading branch information
kzar committed Sep 21, 2022
1 parent 58b2519 commit e84d026
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion integration-test/background/click-to-load-facebook.js
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,14 @@ describe('Test Facebook Click To Load', () => {

expect(facebookSDKRedirect.checked).toBeTrue()
expect(facebookSDKRedirect.alwaysRedirected).toBeFalse()
// Reducing from 3 as failing in ci (https://app.asana.com/0/892838074342800/1202683879327697/f)

// The network is too slow for any requests to have been made.
// Better to mark these tests as pending than to consider requests
// to have been blocked (or not blocked).
if (requestCount === 0) {
pending('Timed out waiting for Facebook requests!')
}

expect(requestCount).toBeGreaterThan(0)
expect(blockCount).toEqual(0)
expect(allowCount).toEqual(requestCount)
Expand Down

0 comments on commit e84d026

Please sign in to comment.