  We study evolution of frequency of a standing electromagnetic (EM) wave in a
resonant optical cavity placed to the expanding manifold described by the
Robertson-Walker metric. One builds a local coordinate system in which
spacetime is locally Minkowskian. However, due to the conformal nature of the
Robertson-Walker metric the conventional transformation to the local inertial
coordinates introduces ambiguity in the physical interpretation of the local
time coordinate. Therefore, contrary to a common-sense expectation, a
straightforward implementation of EEP alone does not allow us to decide whether
atomic clocks ticks at the same rate as the clocks based on EM modes of a
cavity. To resolve the ambiguity we analyzed the cavity rigidity and the
oscillation of its EM modes in an expanding universe by employing the Maxwell
equations. We found out that both the size of the cavity and the EM frequency
experience an adiabatic drift in conformal coordinates as the universe expands.
We set up the oscillation equation for the EM modes, solve it by the WKB
approximation, and reduce the coordinate-dependent quantities to their
counterparts measured by a local observer who counts time with atomic clock.
The solution shows that there is a perfect cancellation of the adiabatic drift
of cavity's frequency by the transformation to local coordinates, and the time
counted by the clocks based on EM modes of cavity has the same rate as that of
atomic clocks. We conclude that there should be no cosmological drift of
frequency of a standing EM wave oscillating in the cavity resonator as compared
to the frequency of atomic clocks. Continuous comparison of the frequency of
the optical cavity resonator against that of atomic clock yields a powerful
null test of the local isotropy of the Hubble expansion and the Einstein
equivalence principle in cosmology.

General Relativity and Quantum Cosmology;Optics