code: def test_write_json_duration() -> None:
      df = pl.DataFrame(
          {
              "a": pl.Series(
                  [91762939, 91762890, 6020836],
                  dtype=pl.Duration(time_unit="ms"),
              )
          }
      )
      assert (
          df.write_json(row_oriented=True)
          == '[{"a":"P1DT5362.939S"},{"a":"P1DT5362.890S"},{"a":"PT6020.836S"}]'
      )
  
imports: from __future__ import annotations
  import datetime
  import io
  import json
  from collections import OrderedDict
  from io import BytesIO
  from typing import TYPE_CHECKING, Any
  import pytest
  import polars
  from polars.testing import assert_frame_equal
label_desc: Use image node_id 20 for calling a global function with example usage: test_write_json_duration() without return types