File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
packages/plugin-lighthouse/src/lib/runner Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -50,7 +50,7 @@ export function toAuditOutputs(
50
50
const auditOutput : AuditOutput = {
51
51
slug,
52
52
score : score ?? 1 , // score can be null
53
- value : Number . parseInt ( value . toString ( ) , 10 ) ,
53
+ value,
54
54
displayValue,
55
55
} ;
56
56
Original file line number Diff line number Diff line change @@ -91,7 +91,7 @@ describe('toAuditOutputs', () => {
91
91
) . not . toThrow ( ) ;
92
92
} ) ;
93
93
94
- it ( 'should parse valid lhr float value to integer ' , ( ) => {
94
+ it ( 'should copy lhr numericValue to audit value as float ' , ( ) => {
95
95
expect (
96
96
toAuditOutputs ( [
97
97
{
@@ -106,7 +106,7 @@ describe('toAuditOutputs', () => {
106
106
displayValue : '2.8 s' ,
107
107
} ,
108
108
] ) ,
109
- ) . toStrictEqual ( [ expect . objectContaining ( { value : 2838 } ) ] ) ;
109
+ ) . toStrictEqual ( [ expect . objectContaining ( { value : 2838.974 } ) ] ) ;
110
110
} ) ;
111
111
112
112
it ( 'should convert null score to 1' , ( ) => {
You can’t perform that action at this time.
0 commit comments