Mann-Whitney U test (Wilcoxon rank-sum test) compares the medians of two groups. Significant difference means that ordinal variable depends on binary variable (group).
In the presence of ties Kolmogorov-Smirnov test should be preferred. Kolmogorov-Smirnov test compares two distribution functions.
Example: Sample of consumers were shown the new advertisement. Each of consumers rated it (1= I liked it very much, 5= I didn't like it at all). Did women perceive the advertisement differently from men?