Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

report: handle underscored not_applicable scoreDisplayMode #6549

Merged
merged 1 commit into from
Nov 13, 2018

Conversation

brendankenny
Copy link
Member

(temporarily) fixes #6540

Adds a check to Util.prepareReportResult to convert any scoreDisplayMode of 'not_applicable' to 'not-applicable' since the API is currently returning the first variant but the report renderer only understands the second.

Ideally we'll fix this at the API level (or, booooo, change the official LH value to the underscored version), but this fix is easier to deploy for now.

See #6371 and #6201 for background.

cc @exterkamp @ebidel

Copy link
Collaborator

@patrickhulce patrickhulce left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@@ -7,6 +7,7 @@

const assert = require('assert');
const Util = require('../../../../report/html/renderer/util.js');
const sampleResult = require('../../../results/sample_v2.json');
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we should add a test of trying to render sample_v2_round_trip.json or better yet, get the no-loss-round-trip test going :)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should definitely do this. And maybe add another puppeteer test to make sure the report looks good. We would have caught this :)

@brendankenny brendankenny merged commit b70d1ca into master Nov 13, 2018
@brendankenny brendankenny deleted the not-underscored branch November 13, 2018 20:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Confusing interface and more
2 participants