Survival data with one intermediate state are described by semi-Markov and Markov models for counting processes whose intensities are defined in terms of two stopping times T-1 < T-2. Problems of goodness-of-fit for these models are studied. The test statistics are proposed by comparing Nelson-Aalen estimators for data stratified according to T1. Asymptotic distributions of these statistics are established in terms of the weak convergence of some random fields. Asymptotic consistency of these test statistics is also established. Simulation studies are included to indicate their numerical performance.