(pdf, df)
| 874 | |
| 875 | @pytest.mark.filterwarnings("ignore::UserWarning") |
| 876 | def test_to_numeric(pdf, df): |
| 877 | import dask.array as da |
| 878 | |
| 879 | pdf.x = pdf.x.astype("str") |
| 880 | expected = pd.to_numeric(pdf.x) |
| 881 | df.x = df.x.astype("str") |
| 882 | result = to_numeric(df.x) |
| 883 | assert_eq(result, expected) |
| 884 | |
| 885 | result = to_numeric("1.0").compute() |
| 886 | assert result == 1.0 |
| 887 | |
| 888 | arr = df.x.to_dask_array() |
| 889 | expected = pd.to_numeric(pdf.x.to_numpy()) |
| 890 | result = to_numeric(arr) |
| 891 | da.assert_eq(result, expected) |
| 892 | |
| 893 | |
| 894 | def test_to_timedelta(pdf, df): |
nothing calls this directly
no test coverage detected