[PyTorch] Additional IValue tests (#49718)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/49718
Improving test coverage in preparation for updating the
implementation of IValue.
ghstack-source-id: 119327373
Test Plan: ivalue_test
Reviewed By: hlu1
Differential Revision: D25674605
fbshipit-source-id: 37a82bb135f75ec52d2d8bd929c4329e8dcc4d25