Follow suggestion by @BobLd, added 2 more test cases for if we want to

support more lenient page size parsing in the future.
This commit is contained in:
mvantzet
2023-03-14 12:33:21 +01:00
parent 048caedd64
commit a07fdb8d45
2 changed files with 4 additions and 2 deletions

View File

@@ -150,8 +150,8 @@
public override bool Equals(object obj)
{
return obj is WidthHeight height &&
Math.Abs(Width - height.Width) < 1 &&
Math.Abs(Height - height.Height) < 1;
Math.Round(Width) == Math.Round(height.Width) &&
Math.Round(Height) == Math.Round(height.Height);
}
public override int GetHashCode()