A hypothesis test examines two opposing hypotheses about a population: the null hypothesis and the alternative hypothesis. From this example the null hypothesis is the sample mean equal to 20. Alternative hypothesis is mean no equal to 20. So, we use one sample t-test to test the truth or null hypothesis