Unit tests for the DataGridScores
component will sometimes not reach 100% coverage.
#2133
Labels
DataGridScores
component will sometimes not reach 100% coverage.
#2133
See this line in the tests and this line in the component, for example.
I think the intention of this code is to make sure that
mockStartDate
is always one day back from the current date, but this code will produce a number rather than a date. If this happens to run on the first day of the month, the result is thatmockStartDate
is0
which will not produce test cases that reach all of the component's code.Replace
new Date().getDate() - 1
with code that will actually find the previous day's date.The text was updated successfully, but these errors were encountered: