CompareOptions configures comparison behavior
| 25 | |
| 26 | // CompareOptions configures comparison behavior |
| 27 | type CompareOptions struct { |
| 28 | // IgnoreColumnOrder ignores the order of columns (compare by name) |
| 29 | IgnoreColumnOrder bool |
| 30 | // IgnoreRowOrder ignores the order of rows (compare as sets) |
| 31 | IgnoreRowOrder bool |
| 32 | // IgnoreColumnNames ignores column name differences (only compare data) |
| 33 | IgnoreColumnNames bool |
| 34 | // FloatTolerance is the tolerance for floating point comparisons |
| 35 | FloatTolerance float64 |
| 36 | // TimeTolerance is the tolerance for timestamp comparisons |
| 37 | TimeTolerance time.Duration |
| 38 | // IgnoreCase ignores case differences in string comparisons |
| 39 | IgnoreCase bool |
| 40 | // IgnoreWhitespace trims whitespace before comparing strings |
| 41 | IgnoreWhitespace bool |
| 42 | // AllowNullEquality treats NULL == NULL as true for comparisons |
| 43 | AllowNullEquality bool |
| 44 | // IgnoreColumns lists columns to skip in comparison |
| 45 | IgnoreColumns []string |
| 46 | } |
| 47 | |
| 48 | // DefaultCompareOptions returns sensible defaults for comparison |
| 49 | func DefaultCompareOptions() CompareOptions { |
nothing calls this directly
no outgoing calls
no test coverage detected