Electric potential distribution in nanoscale electroosmosis has been investigated using the nonequilibrium molecular dynamics (NEMD), whose results are compared with the continuum based Poisson-Boltzmann (PB) theory. If the bin size of the MD simulation is no smaller than a molecular diameter and the focusing region is limited to the diffusion layer, the ionic density profiles on the bins of the MD results agree well with the predictions based on the Poisson-Boltzmann theory for low and moderate bulk ionic concentrations. The PB equation breaks down at high bulk ionic concentrations, which is also consistent with the macroscopic description.