@@ -183,6 +183,7 @@ class Dashboard extends Component {
183
183
let infoHistoryAnalysisLabelsTmp = [ ] ;
184
184
const failingListTmp = [ ] ;
185
185
const passingListTmp = [ ] ;
186
+ const erroringListTmp = [ ] ;
186
187
response . json ( ) . then ( historyResultJSON => {
187
188
let infoHistoryAnalysisKey = "" ;
188
189
Object . keys ( historyResultJSON ) . forEach ( key => {
@@ -203,6 +204,7 @@ class Dashboard extends Component {
203
204
infoHistoryAnalysisTmp [ infoHistoryAnalysisKey ] = {
204
205
passed : 0 ,
205
206
failed : 0 ,
207
+ error : 0 ,
206
208
} ;
207
209
}
208
210
historyResultJSON [ key ] . results . forEach ( currentResult => {
@@ -221,10 +223,12 @@ class Dashboard extends Component {
221
223
. forEach ( key => {
222
224
failingListTmp . push ( infoHistoryAnalysisTmp [ key ] . failed ) ;
223
225
passingListTmp . push ( infoHistoryAnalysisTmp [ key ] . passed ) ;
226
+ erroringListTmp . push ( infoHistoryAnalysisTmp [ key ] . error ) ;
224
227
} ) ;
225
228
const { infoHistoryAnalysis } = this . state ;
226
229
const { passingList } = this . state ;
227
230
const { failingList } = this . state ;
231
+ const { erroringList } = this . state ;
228
232
const { infoHistoryAnalysisLabels } = this . state ;
229
233
230
234
if ( timeFilter === "time_range=today" ) {
@@ -244,13 +248,15 @@ class Dashboard extends Component {
244
248
infoHistoryAnalysisLabelsTmp
245
249
) ||
246
250
! isEqual ( passingList , passingListTmp ) ||
247
- ! isEqual ( failingList , failingListTmp )
251
+ ! isEqual ( failingList , failingListTmp ) ||
252
+ ! isEqual ( erroringList , erroringListTmp )
248
253
) {
249
254
this . setState ( {
250
255
infoHistoryAnalysis : infoHistoryAnalysisTmp ,
251
256
infoHistoryAnalysisLabels : infoHistoryAnalysisLabelsTmp ,
252
257
passingList : passingListTmp ,
253
258
failingList : failingListTmp ,
259
+ erroringList : erroringListTmp ,
254
260
} ) ;
255
261
}
256
262
} ) ;
@@ -435,7 +441,7 @@ class Dashboard extends Component {
435
441
for ( let counter = 0 ; counter < 24 ; counter += 1 ) {
436
442
const current = String ( Number ( first ) + increment * counter ) ;
437
443
if ( ! keys . includes ( current ) ) {
438
- final [ current ] = { passed : 0 , failed : 0 } ;
444
+ final [ current ] = { passed : 0 , failed : 0 , error : 0 } ;
439
445
}
440
446
}
441
447
} else {
@@ -444,7 +450,7 @@ class Dashboard extends Component {
444
450
for ( let counter = 0 ; counter < numDays ; counter += 1 ) {
445
451
const current = String ( Number ( first ) + increment * counter ) ;
446
452
if ( ! keys . includes ( current ) ) {
447
- final [ current ] = { passed : 0 , failed : 0 } ;
453
+ final [ current ] = { passed : 0 , failed : 0 , error : 0 } ;
448
454
}
449
455
}
450
456
}
@@ -530,6 +536,7 @@ class Dashboard extends Component {
530
536
const { infoHistoryAnalysisLabels } = this . state ;
531
537
const { failingList } = this . state ;
532
538
const { passingList } = this . state ;
539
+ const { erroringList } = this . state ;
533
540
const infoHistoryAnalysisData = {
534
541
labels : infoHistoryAnalysisLabels ,
535
542
datasets : [
@@ -545,7 +552,7 @@ class Dashboard extends Component {
545
552
borderDashOffset : 0.0 ,
546
553
borderJoinStyle : "miter" ,
547
554
pointBorderColor : colorGreenHover ,
548
- pointBackgroundColor : "#fff" ,
555
+ pointBackgroundColor : colorGreen ,
549
556
pointBorderWidth : 4 ,
550
557
pointHoverRadius : 5 ,
551
558
pointHoverBackgroundColor : colorGreen ,
@@ -567,7 +574,7 @@ class Dashboard extends Component {
567
574
borderDashOffset : 0.0 ,
568
575
borderJoinStyle : "miter" ,
569
576
pointBorderColor : colorRedHover ,
570
- pointBackgroundColor : "#fff" ,
577
+ pointBackgroundColor : colorRed ,
571
578
pointBorderWidth : 4 ,
572
579
pointHoverRadius : 5 ,
573
580
pointHoverBackgroundColor : colorRed ,
@@ -577,6 +584,28 @@ class Dashboard extends Component {
577
584
pointHitRadius : 10 ,
578
585
data : failingList ,
579
586
} ,
587
+ {
588
+ label : "Error Analyses" ,
589
+ fill : false ,
590
+ lineTension : 0.1 ,
591
+ borderWidth : 5 ,
592
+ backgroundColor : colorGray ,
593
+ borderColor : colorGrayHover ,
594
+ borderCapStyle : "butt" ,
595
+ borderDash : [ ] ,
596
+ borderDashOffset : 0.0 ,
597
+ borderJoinStyle : "miter" ,
598
+ pointBorderColor : colorGrayHover ,
599
+ pointBackgroundColor : colorGray ,
600
+ pointBorderWidth : 4 ,
601
+ pointHoverRadius : 5 ,
602
+ pointHoverBackgroundColor : colorGray ,
603
+ pointHoverBorderColor : colorGrayHover ,
604
+ pointHoverBorderWidth : 4 ,
605
+ pointRadius : 3 ,
606
+ pointHitRadius : 10 ,
607
+ data : erroringList ,
608
+ } ,
580
609
] ,
581
610
} ;
582
611
0 commit comments