Actually,, as shown by the various stories above,, yes,, some folks would practice with .22's in their homes/basements. And yes,, there were .22 cal bullet traps sold many years ago. Often,, the folks would use .22 shorts for the ammo.
As for shooting rats etc,, I have a friend,, who was raised in Asheville NC,, who lived in a plain older house. The walls were cement blocks. And yes,, the occasional rat would get in. When they suspected it,, they would turn out the lights in the kitchen,, except for a single bulb that lit the area just enough. They would hang a small piece of bacon from a string,, and sit in the living room & shoot the rats as they tried to get the bacon. He & I were just talking about that a few weeks ago.