Skip to content

Commit

Permalink
[fix](regression) fix regression framework bug: if real test result i…
Browse files Browse the repository at this point in the history
…s negative, it will miss check test result apache#25734 (apache#25734) (apache#26551)
  • Loading branch information
jacktengg authored and gnehil committed Dec 4, 2023
1 parent 12c7b71 commit a745f7f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
0.11111111111111111111111111111111100000 11111111111111111111111111111.1100000000 0.11111111111111111111111111111111100000 11111111111111111111111111111.110

-- !sql --
0.11111111111111111111111111111111100000 9223372036854775.807 0.11111111111111111111111111111111100000 11111111111111111111111111111.110
0.11111111111111111111111111111111100000 -999999999999999.999 0.11111111111111111111111111111111100000 11111111111111111111111111111.110

-- !sql --
0.11111111111111111111111111111111100000 -9223.372036854775808 0.11111111111111111111111111111111100000 11111111111111111111111111111.110
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ class OutputUtils {
double expectDouble = Double.parseDouble(expectCell)
double realDouble = Double.parseDouble(realCell)

double realRelativeError = Math.abs(expectDouble - realDouble) / realDouble
double realRelativeError = Math.abs(expectDouble - realDouble) / Math.abs(realDouble)
double expectRelativeError = 1e-8

if (expectRelativeError < realRelativeError) {
Expand Down

0 comments on commit a745f7f

Please sign in to comment.