Consolidated some tests into a custom assertion