code: def test_timedelta_to_str():
      assert (round_td_str(pd.Timedelta("1W"))) == "7D"
      assert (timedelta_to_str(pd.Timedelta("1W"))) == "7D"
      assert (timedelta_to_str(pd.Timedelta("1W") * -1)) == "NEG7D"
      assert timedelta_to_str(pd.Timedelta("1s 114ms")) == "1.114s"
      assert round_td_str(pd.Timedelta("14.4ms")) == "14ms"
      assert round_td_str(pd.Timedelta("501ms")) == "501ms"
      assert round_td_str(pd.Timedelta("951ms")) == "1s"
      assert round_td_str(pd.Timedelta("950ms")) == "950ms"
      assert round_td_str(pd.Timedelta("949ms")) == "949ms"
      assert round_td_str(pd.Timedelta("500ms")) == "500ms"
      assert round_td_str(pd.Timedelta("14.4ms")) == "14ms"
      assert round_td_str(pd.Timedelta("14.6ms")) == "15ms"
      assert round_td_str(pd.Timedelta("1h 14.4us")) == "1h"
      assert round_td_str(pd.Timedelta("1128.9us")) == "1ms"
      assert round_td_str(pd.Timedelta("128.9us")) == "129us"
      assert round_td_str((pd.Timedelta("14ns"))) == "14ns"
      # zero should return None
      assert round_td_str((pd.Timedelta("0ns"))) is None
  
file_path: plotly-resampler/tests/test_utils.py
imports: import pandas
  import plotly.graph_objects
  from plotly_resampler import FigureResampler, FigureWidgetResampler
  from plotly_resampler.figure_resampler.utils import is_figure, is_figurewidget, is_fr, is_fwr, round_number_str, round_td_str, timedelta_to_str
label_desc: Use image node_id 5 for calling a global function with example usage: test_timedelta_to_str() without return types