Add tests for public methods of base Layer class.
Add tests for public methods of base Layer class.

Also split out tests for PureLayer and Fn into their own test classes, and
simplify some test names accordingly.

PiperOrigin-RevId: 309453558

google/trax,google/trax