code: def test_max_distance_how_right(self):
      left = geopandas.GeoDataFrame(
          {"geometry": [Point(1, 1), Point(2, 2)]}
      )
      right = geopandas.GeoDataFrame(
          {"geometry": [Point(0, 0), Point(1, 1)]}
      )
      joined = sjoin_nearest(
          left,
          right,
          how="right",
          max_distance=1,
          distance_col="distances",
      )
      expected = right.copy()
      expected["index_left"] = [np.nan, 0]
      expected["distances"] = [np.nan, 0]
      expected = expected[["index_left", "geometry", "distances"]]
      assert_geodataframe_equal(joined, expected)
  
imports: import math
  from typing import Sequence
  import numpy
  import pandas
  import shapely
  from shapely.geometry import Point, Polygon, GeometryCollection
  import geopandas
  import geopandas._compat
  from geopandas import GeoDataFrame, GeoSeries, read_file, sjoin, sjoin_nearest
  from geopandas.testing import assert_geodataframe_equal, assert_geoseries_equal
  from pandas.testing import assert_frame_equal, assert_series_equal
  import pytest
label_desc: Use image node_id 10 for calling the TestNearest obj's underlying member method code with example usage: obj.test_max_distance_how_right() without return types