code: def test_sort_dates_multiples() -> None:
      df = pl.DataFrame(
          [
              pl.Series(
                  "date",
                  [
                      "2021-01-01 00:00:00",
                      "2021-01-01 00:00:00",
                      "2021-01-02 00:00:00",
                      "2021-01-02 00:00:00",
                      "2021-01-03 00:00:00",
                  ],
              ).str.strptime(pl.Datetime, "%Y-%m-%d %T"),
              pl.Series("values", [5, 4, 3, 2, 1]),
          ]
      )
  
      expected = [4, 5, 2, 3, 1]
  
      # datetime
      out: pl.DataFrame = df.sort(["date", "values"])
      assert out["values"].to_list() == expected
  
      # Date
      out = df.with_columns(pl.col("date").cast(pl.Date)).sort(
          ["date", "values"]
      )
      assert out["values"].to_list() == expected
  
imports: from __future__ import annotations
  from datetime import date, datetime
  from typing import Any
  import pytest
  import polars
  from polars.testing import assert_frame_equal, assert_series_equal
label_desc: Use image node_id 1 for calling a global function with example usage: test_sort_dates_multiples() without return types