This is yet another idiosyncrasy of Android, the /sbin directory is in the $PATH of the adb shell used for running the tests on the emulator or on a device connected with usb to the build platform, and /sbin is readable and searchable only by root. For a plain user, the loop over exec_array[] in child_exec() at _posixsubprocess.c sets saved_errno to EACCES after failing to exec /sbin/some_non_existent_program.
The patch fixes these failing tests on Android API 24: test_dtrace test_shutil test_subprocess.