Online tests offer many advantages but they still belong to assessment, which may make learners have anxiety. Thus, students may experience certain emotion. Academic emotion is a branch of emotion and has great effects on student learning. Such effects can be associated with individual differences, especially prior knowledge. To this end, this study examined the influences of academic emotion and prior knowledge in the context of an online test. The results indicated that the positive academic emotion of high prior knowledge learners (HPKs) and low prior knowledge learners (LPKs) was connected with their pre-test scores while no connection was found for their post-test scores. Additionally, HPKs had higher positive academic emotion and lower negative academic emotion than LPKs. On the other hand, HPKs got better pre-and post-test scores than LPKs whereas LPKs had higher gain scores. Furthermore, HPKs and LPKs exhibited different behavior sequences. More specifically, LPKs tended to acquire small-scaled information from the Chinese hint only while HPKs preferred to obtain both small-scaled information and large-scaled information from the Chinese hint and sentence hint, respectively. According to the findings of this study, we develop a framework, which can be applied to help understand the needs of HPKs and LPKs.