The treatment of mixing processes is still one of the major uncertainties in 1D stellar evolution models. This is mostly due to the need to parametrize and approximate aspects of hydrodynamics in hydrostatic codes. In particular, the effect of hydrodynamic instabilities in rotating stars, for example, dynamical shear instability, evades consistent description. We intend to study the accuracy of the diffusion approximation to dynamical shear in hydrostatic stellar evolution models by comparing 1D models to a first-principle hydrodynamics simulation starting from the same initial conditions. We chose an initial model calculated with the stellar evolution code GENEC that is just at the onset of a dynamical shear instability but does not show any other instabilities (e.g., convection). This was mapped to the hydrodynamics code SLH to perform a 2D simulation in the equatorial plane. We compare the resulting profiles in the two codes and compute an effective diffusion coefficient for the hydro simulation. Shear instabilities develop in the 2D simulation in the regions predicted by linear theory to become unstable in the 1D model. Angular velocity and chemical composition is redistributed in the unstable region, thereby creating new unstable regions. Eventually the 2D simulation settles in a symmetric, steady state, which is Richardson stable everywhere, whereas the instability remains for longer in the 1D model due to current limitations in the 1D code. A spatially resolved diffusion coefficient is extracted by comparing the initial and final profiles of mean atomic mass. The presented simulation gives a first insight on hydrodynamics of shear instabilities in a real stellar environment and even allows us to directly extract an effective diffusion coefficient. We see evidence for a critical Richardson number of 0.25 as regions above this value remain stable for the course of the simulation.