It’s not clear to me what exactly is tested by the Mann–Whitney U test (also called Wilcoxon rank-sum test).
First, assume independence of the observations, and ordinality of the data.
My understanding is that under these conditions, the Mann-Whitney U is testing the hypothesis of stochastic equality, that is
$H_0 : P(X > Y) = P(Y > X)$
$H_1 : P(X > Y) \neq P(Y > X)$
Additionally, if we assume that the distributions have the same shape but not the same location, then the Mann-Whitney U becomes a test of equality of medians. If we also add the assumption of symmetricality, then the Mann-Whitney U becomes a test of equality of means (assuming they exist).
However, some sources say the Mann-Whitney U assumes equal variance, which confuses me. It seems to me the Mann-Whitney U either makes no assumptions about the shape of the two distributions for the stochastic equality test, or assumes a difference in location only for the median test interpretation.
Even more confusing is that the Brunner-Munzel test is often described as “relaxing” the assumption of equal variance of the Mann-Whitney U. The test of hypotheses is the same as the one I mentioned for the Mann-Whitney U earlier, that is
$H_0 : P(X > Y) = P(Y > X)$
$H_1 : P(X > Y) \neq P(Y > X)$
So it seems to be testing the exact same hypothesis as the Mann-Whitney U, just without the “test of equality of medians” interpretation.
Are the hypotheses for the Mann-Whitney U and Brunner-Munzel tests the same? If not, how do they differ?