Add tests for libtorch macOS binary (#25208)
Summary:
This PR adds basic and dependency tests for libtorch macOS binary, so that we don't have issues like https://github.com/pytorch/pytorch/issues/14727 in the future.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/25208
Differential Revision: D18001189
Pulled By: yf225
fbshipit-source-id: 89be1947b5bc094fcc02b0f268b9d8ebaf0f6700