refactor core tests and components tests