package com.jasamedika.medifirst2000.dao.test;

import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;

import java.util.List;

import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.test.context.ContextConfiguration;
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
import org.springframework.transaction.annotation.Transactional;

import com.jasamedika.medifirst2000.dao.GenericViewDao;
import com.jasamedika.medifirst2000.dao.PapPernapasanDao;
import com.jasamedika.medifirst2000.dao.PasienDao;
import com.jasamedika.medifirst2000.entities.GenericView;

@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration("classpath*:com/jasamedika/**/applicationContext.xml")
public class GenerateNoCmDaoTest {

	@Autowired
	private PasienDao pasienDao;
	
	@Test
	@Transactional
	public void testFindNoCmDaoSelect() {
		List<String> list=pasienDao.findAllNoCm();
		assertNotNull(list);
		System.out.println("LISSSSSSSSSST : "+list.size());
    	assertEquals("8", list.size());
	}
}