@@ -422,12 +422,25 @@ def initialize_camera(self, enable):
422422
423423 def test_raycast_mapping_geom_to_body_id (self ):
424424 def build_mjv_select (mock_body_id , mock_geom_id , mock_position ):
425+
425426 def mock_select (
426- m , d , vopt , aspectratio , relx , rely , scn , selpnt , geomid , skinid ):
427- del m , d , vopt , aspectratio , relx , rely , scn , skinid # Unused.
427+ m ,
428+ d ,
429+ vopt ,
430+ aspectratio ,
431+ relx ,
432+ rely ,
433+ scn ,
434+ selpnt ,
435+ geomid ,
436+ flexid ,
437+ skinid ,
438+ ):
439+ del m , d , vopt , aspectratio , relx , rely , scn , flexid , skinid # Unused.
428440 selpnt [:] = mock_position
429441 geomid [:] = mock_geom_id
430442 return mock_body_id
443+
431444 return mock_select
432445
433446 geom_id = 0
@@ -444,9 +457,11 @@ def mock_select(
444457 np .testing .assert_array_equal (hit_world_pos , world_pos )
445458
446459 def test_raycast_hitting_empty_space (self ):
460+
447461 def mock_select (
448- m , d , vopt , aspectratio , relx , rely , scn , selpnt , geomid , skinid ):
449- del (m , d , vopt , aspectratio , relx , rely , scn , selpnt , geomid ,
462+ m , d , vopt , aspectratio , relx , rely , scn , selpnt , geomid , flexid , skinid
463+ ):
464+ del (m , d , vopt , aspectratio , relx , rely , scn , selpnt , geomid , flexid ,
450465 skinid ) # Unused.
451466 mock_body_id = - 1 # Nothing selected.
452467 return mock_body_id
@@ -459,13 +474,26 @@ def mock_select(
459474
460475 def test_raycast_maps_coordinates_to_viewport_space (self ):
461476 def build_mjv_select (expected_aspect_ratio , expected_viewport_pos ):
477+
462478 def mock_select (
463- m , d , vopt , aspectratio , relx , rely , scn , selpnt , geomid , skinid ):
464- del m , d , vopt , scn , selpnt , geomid , skinid # Unused.
479+ m ,
480+ d ,
481+ vopt ,
482+ aspectratio ,
483+ relx ,
484+ rely ,
485+ scn ,
486+ selpnt ,
487+ geomid ,
488+ flexid ,
489+ skinid ,
490+ ):
491+ del m , d , vopt , scn , selpnt , geomid , flexid , skinid # Unused.
465492 self .assertEqual (expected_aspect_ratio , aspectratio )
466493 np .testing .assert_array_equal (expected_viewport_pos , [relx , rely ])
467494 mock_body_id = 0
468495 return mock_body_id
496+
469497 return mock_select
470498
471499 viewport_pos = [.5 , .5 ]
0 commit comments