Skip to content

Commit

Permalink
tests(smoke): restore dbw_tester exception assertions (#11836)
Browse files Browse the repository at this point in the history
  • Loading branch information
paulirish authored Dec 16, 2020
1 parent a6738e0 commit 9dbb0a5
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 49 deletions.
1 change: 1 addition & 0 deletions lighthouse-cli/test/cli/__snapshots__/index-test.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -1454,6 +1454,7 @@ Object {
Object {
"blankPage": "about:blank",
"blockedUrlPatterns": Array [
"*.css",
"*.jpg",
"*.jpeg",
"*.png",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -210,53 +210,43 @@ const expectations = [
'errors-in-console': {
score: 0,
details: {
items: {
length: '7 +/- 1',
// COMPAT: In 89.0.4351.0 we observed one additional runtime error and it's origin is currently unknown
// TODO: Investigate and resolve it's presence. https://github.com/GoogleChrome/lighthouse/issues/11803
// {
// source: 'exception',
// description: 'TypeError: the given value is not a Promise',
// url: 'http://localhost:10200/dobetterweb/third_party/aggressive-promise-polyfill.js',
// },
},
// items: [
// {
// source: 'other',
// description: 'Application Cache Error event: Manifest fetch failed (404) http://localhost:10200/dobetterweb/clock.appcache',
// url: 'http://localhost:10200/dobetterweb/dbw_tester.html',
// },
// {
// source: 'exception',
// description: /^Error: A distinctive error\s+at http:\/\/localhost:10200\/dobetterweb\/dbw_tester.html:\d+:\d+$/,
// url: 'http://localhost:10200/dobetterweb/dbw_tester.html',
// },
// {
// source: 'network',
// description: 'Failed to load resource: the server responded with a status of 404 (Not Found)',
// url: 'http://localhost:10200/dobetterweb/unknown404.css?delay=200',
// },
// {
// source: 'network',
// description: 'Failed to load resource: the server responded with a status of 404 (Not Found)',
// url: 'http://localhost:10200/dobetterweb/fcp-delayer.js?delay=5000',
// },
// {
// source: 'network',
// description: 'Failed to load resource: the server responded with a status of 404 (Not Found)',
// url: 'http://localhost:10200/favicon.ico',
// },
// {
// source: 'network',
// description: 'Failed to load resource: the server responded with a status of 404 (Not Found)',
// url: 'http://localhost:10200/dobetterweb/unknown404.css?delay=200',
// },
// {
// source: 'console.error',
// description: 'Error! Error!',
// url: 'http://localhost:10200/dobetterweb/dbw_tester.html',
// },
// ],
items: [
{
source: 'other',
description: 'Application Cache Error event: Manifest fetch failed (404) http://localhost:10200/dobetterweb/clock.appcache',
url: 'http://localhost:10200/dobetterweb/dbw_tester.html',
},
{
source: 'exception',
description: /^Error: A distinctive error\s+at http:\/\/localhost:10200\/dobetterweb\/dbw_tester.html:\d+:\d+$/,
url: 'http://localhost:10200/dobetterweb/dbw_tester.html',
},
{
source: 'console.error',
description: 'Error! Error!',
url: 'http://localhost:10200/dobetterweb/dbw_tester.html',
},
{
source: 'network',
description: 'Failed to load resource: the server responded with a status of 404 (Not Found)',
url: 'http://localhost:10200/dobetterweb/unknown404.css?delay=200',
},
{
source: 'network',
description: 'Failed to load resource: the server responded with a status of 404 (Not Found)',
url: 'http://localhost:10200/dobetterweb/fcp-delayer.js?delay=5000',
},
{
source: 'network',
description: 'Failed to load resource: the server responded with a status of 404 (Not Found)',
url: 'http://localhost:10200/favicon.ico',
},
{
source: 'network',
description: 'Failed to load resource: the server responded with a status of 404 (Not Found)',
url: 'http://localhost:10200/dobetterweb/unknown404.css?delay=200',
},
],
},
},
'is-on-https': {
Expand Down
3 changes: 1 addition & 2 deletions lighthouse-core/config/default-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -175,8 +175,7 @@ const defaultConfig = {
passName: 'redirectPass',
loadFailureMode: 'warn',
// Speed up the redirect pass by blocking stylesheets, fonts, and images
// TODO: restore blocked *.css when https://github.com/GoogleChrome/lighthouse/issues/11803 is resolved.
blockedUrlPatterns: ['*.jpg', '*.jpeg', '*.png', '*.gif', '*.svg', '*.ttf', '*.woff', '*.woff2'],
blockedUrlPatterns: ['*.css', '*.jpg', '*.jpeg', '*.png', '*.gif', '*.svg', '*.ttf', '*.woff', '*.woff2'],
gatherers: [
'http-redirect',
],
Expand Down

0 comments on commit 9dbb0a5

Please sign in to comment.