In general, when a hypothesis is evaluated from a statistical point of view, it takes into consideration the measures of central tendency, within which the mean or average, its variances and standard deviations (variations, within a normal distribution, which is known as "bell of Gauss"), is the central value resulting from the sum of all measurements, between the number of subjects measured, either in the population, or in a sample of this population.
Although the variables, according to the theory of Stevens (1946), to be measured can be nominal, ordinal, interval or proportion, traditionally, it is consider that the most objective is the interval and proportion, since they are numerical and quantitative, and the hypothesis tests that can be applied are, therefore, "robust" that is, they give numerical results, which are always more objective or "hard" (not subject to subjective or personal interpretation)
There are other measures of central tendency that can also be taken into consideration when testing the hypothesis, for example, the median; however, unlike the average, it implies that the population under study does not show a "normal" behavior, but that there is a positive or negative trend (the curve is not a perfect bell but has a "hump" on the left or right, where most of the results of the evaluated subjects are group, but not all are there as they extend along one extreme or another) in which case, the average of all the measurements, is different by values extremes. A normal distribution will ideally have a similar average, mode or median, all convergent in the middle of the bell.
Taking up your question: "... Why are class averages ..." - Interpreting your question as the average grades obtained in a course X in a classroom Y with, for example n = 30 students, are considered when evaluating different hypotheses it is because habitually, such grades are awarded in numbers (for example 0.0 to 10.0) and a room with 30 students, probably, can be considered as "a statistically significant sample". Both aspects: quantitative variable (measured in terms of the average of each student) and significant and representative sample (n = 30, enough students to transpose the results to all students in that course), are two desirable aspects of making statistical inferences and tests whether a given hypothesis is true (working hypothesis) or false (null hypothesis), so many researchers might find useful to use these results and scenario.
Though, in general terms "class" can be any variable measured in any population, so clarification would be useful, to give you a more detailed answer.
For more detail, I suggest you review the bibliography referred below, to understand more the measures of central tendency, and gently suggest you be a little more specific in your question (what means for you "class averages") Greetings!
Words:465
Keywords: measures of central tendency, hypothesis testing, type of variables
Reference: Warner, R. M. (2012). Applied statistics from bivariate through multivariate techniques (2nd ed.). Thousand Oaks, CA: Sage Publications.