As a key step in integration testing, the research on the class integration test order generation problem is conducive to finding unknown bugs and improving the efficiency and quality of software testing. The challenge of this problem is sorting the classes to be integrated to minimize the required stubbing cost. However, the existing approaches of generating class integration test orders cannot satisfy this requirement well. Considering the excellent performance of reinforcement learning in sequence decision problems, this paper proposes a class integration test order generation approach based on Sarsa algorithm, which is belongs to a data-driven model-free reinforcement learning algorithm. This approach takes the stubbing complexity as the indicator to evaluate the stubbing cost and uses it to measure the quality of class integration test order. The Sarsa algorithm is used to train the agent, and three indicators such as test return, the number of removed inter-class dependencies, and the number of cycles are integrated into the design of the reward function to evaluate the merits of the current action. The optimal strategy is obtained in multiple training, so as to solve the class integration test order generation problem. The experimental results on 10 systems show that the class integration test order generation approach based on Sarsa algorithm can generate the class integration test orders with lower stubbing cost.