Spectral Based Testing of the Martingale Hypothesis