Google Inc. designed its self-driving cars to follow the rules of the road. Now it’s teaching them to drive like people, by cutting corners, edging into intersections and crossing double-yellow lines.

Humans expect drivers to avoid collisions. But Google’s robots assume the worst and tap the brakes frequently as their digital “eyes” spot potential dangers, sometimes prompting other drivers to stop abruptly.

The...