Skip to content

Commit

Permalink
Fix test for double comparison by using precision
Browse files Browse the repository at this point in the history
  • Loading branch information
sveinungf committed Aug 11, 2024
1 parent d6276ab commit a7af7ae
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion SpreadCheetah.Test/Tests/SpreadsheetStyledRowTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -511,7 +511,7 @@ public async Task Spreadsheet_AddRow_DateTimeCell(bool withDefaultDateTimeFormat
using var workbook = new XLWorkbook(stream);
var worksheet = workbook.Worksheets.Single();
var actualCell = worksheet.Cell(1, 1);
Assert.Equal(value.ToOADate(), actualCell.Value.GetUnifiedNumber());
Assert.Equal(value.ToOADate(), actualCell.Value.GetUnifiedNumber(), 0.0005);
Assert.Equal(expectedNumberFormat, actualCell.Style.NumberFormat.Format);
Assert.True(actualCell.Style.Font.Italic);
}
Expand Down

0 comments on commit a7af7ae

Please sign in to comment.