[testing] add `broadcasts_input` and verifies the behaviour for inplace_variant. (#55771)
Summary:
Fixes https://github.com/pytorch/pytorch/issues/55595
* Add `broadcasts_input` attribute to SampleInput
* Update test_variant_consistency_eager to verify that sample with `broadcasts_input==True` and inplace variant raises an error.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/55771
Reviewed By: jbschlosser, ngimel
Differential Revision: D27760530
Pulled By: mruberry
fbshipit-source-id: feb0658730d4cff483848a5ade9512837a65c24c