I understand that the t-test is used to test the difference in means for two populations when the populations have relatively similar variances, the units are independent, and they are normal (especially with smaller sample sizes).
However, I was wondering how t-tests are used to look at the difference in the distributions of data between two groups? I am asking this because it's basically the phrasing used by the question I'm trying to answer. It asks to compare whether the distributions of the item of interest are different using a t-test.
The reason that I am confused is, even though I understand the mean is a product of the distribution and t-tests may be strongly affected by outliers so the t-test might give some information about two distributions, there could be a case where the two distributions were very similar but the effect size was large simply because they were centered at different means, and there could be a case where the two distributions looked funky with difference variances and whatnot, and that could lead to the same t-stat. So how would to be able to tell anything from a t-test?