factor out core tests into separate file