BUG: sandwich_covariance: fix typo, add simple test, closes #980