This paper presents an analytic dynamic model and a geometric numerical integrator for spacecraft with reaction wheel assemblies. According to Lagrangian mechanics on an abstract Lie group, Euler-Lagrange equations are derived without any restrictive assumptions on the configuration of reaction wheels. This yields the most generalized reaction wheel dynamic model, that can possibly include the effects of arbitrary mass distribution about their spin axes, such as reaction wheel imbalance. The second part is focused on constructing a geometric numerical integrator, referred to as Lie group variational integrator, that provides long-term structural stability in simulating reaction wheel dynamics accurately. These are illustrated by a numerical example.