code: def test_end_time(self):
      # GH#17157
      index = period_range(
          freq="M", start="2016-01-01", end="2016-05-31"
      )
      expected_index = date_range(
          "2016-01-01", end="2016-05-31", freq="ME"
      )
      expected_index += Timedelta(1, "D") - Timedelta(1, "ns")
      tm.assert_index_equal(index.end_time, expected_index)
  
imports: import pytest
  from pandas import Timedelta, date_range, period_range
  import pandas._testing
label_desc: Use image node_id 2 for calling the TestPeriodIndexOps obj's underlying member method code with example usage: obj.test_end_time() without return types