We report on the vibrational and electronic response of GaP and ZnSe subjected to resonant coherent Raman excitation by picosecond-laser light and probed with time-resolved coherent anti-Stokes Raman scattering. Previously reported measurements of the dephasing time of longitudinal optical phonons and of the third-order nonlinear electronic susceptibility in GaP are extended to include ZnSe. The temperature dependence of the dephasing time of coherent phonons is determined and is compared to that obtained from spontaneous (incoherent) Raman scattering. The experimental and analytical methods are reported in detail.