You need to run your test with a Spring context and a transaction manager, e.g.,
@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration(locations = {"/your-applicationContext.xml"})
@TransactionConfiguration(transactionManager="txMgr")
public class StudentSystemTest {
@Test
public void testTransactionalService() {
// test transactional service
}
@Test
@Transactional
public void testNonTransactionalService() {
// test non-transactional service
}
}
See chapter 3.5.8. Transaction Management
of the Spring reference for further details.