Method: Polars::Testing#assert_frame_equal
- Defined in:
- lib/polars/testing.rb
#assert_frame_equal(left, right, check_row_order: true, check_column_order: true, check_dtype: true, check_exact: false, rtol: 1e-5, atol: 1e-8, categorical_as_str: false) ⇒ nil
Assert that the left and right frame are equal.
Raises a detailed AssertionError if the frames differ.
This function is intended for use in unit tests.
31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 |
# File 'lib/polars/testing.rb', line 31 def assert_frame_equal( left, right, check_row_order: true, check_column_order: true, check_dtype: true, check_exact: false, rtol: 1e-5, atol: 1e-8, categorical_as_str: false ) lazy = _assert_correct_input_type(left, right) if lazy left, right = left.collect, right.collect end Plr.assert_dataframe_equal_rb( left._df, right._df, check_row_order, check_column_order, check_dtype, check_exact, rtol, atol, categorical_as_str, ) end |