<commit_before>package org.motech.itests;

import java.io.InputStream;
import java.net.URL;
import java.util.GregorianCalendar;
import java.util.Properties;

import javax.xml.datatype.DatatypeFactory;
import javax.xml.datatype.XMLGregorianCalendar;
import javax.xml.namespace.QName;

import junit.framework.TestCase;

import org.motech.Gender;
import org.motech.Registrar;
import org.motech.RegistrarService;

public class RegistrarITCase extends TestCase {

	XMLGregorianCalendar time;
	Registrar reg;

	@Override
	protected void setUp() throws Exception {
		Properties testProps = new Properties();
		InputStream testPropStream = getClass().getResourceAsStream(
				"/motech-it-test.properties");
		testProps.load(testPropStream);
		reg = new RegistrarService(new URL(testProps
				.getProperty("motech.wsdlurl")), new QName(
				"http://motech.org/", "RegistrarService")).getRegistrarPort();
		time = DatatypeFactory.newInstance().newXMLGregorianCalendar(
				new GregorianCalendar());
	}

	@Override
	protected void tearDown() throws Exception {
		reg = null;
		time = null;
	}

	public void testRegNurse() throws Exception {
		reg.registerNurse("Gaylord", "37694676488", "A-Clinic");
	}

	public void testRegMother() throws Exception {
		reg.registerMother("37694676488", time, "CAPNCRUNCH", "Betty",
				"KFJHKF", "HDJHJDKD", 12, 313, "4674676747", time, 1, 1);
	}

	public void testRegPatient() throws Exception {
		reg.registerPatient("37694676488", "HONEYGRAHAMS", "<NAME>",
				"DHJGDJK", "HDHJHDJK", 23, Gender.MALE, 1232, "4674676747");
	}

	public void testRegPregnancy() throws Exception {
		reg.registerPregnancy("37694676488", time, "HONEYGRAHAMS", time, 2, 23);
	}

}<commit_msg>Added MaternalVisit integration test case<commit_after>package org.motech.itests;

import java.io.InputStream;
import java.net.URL;
import java.util.GregorianCalendar;
import java.util.Properties;

import javax.xml.datatype.DatatypeFactory;
import javax.xml.datatype.XMLGregorianCalendar;
import javax.xml.namespace.QName;

import junit.framework.TestCase;

import org.motech.Gender;
import org.motech.Registrar;
import org.motech.RegistrarService;

public class RegistrarITCase extends TestCase {

	XMLGregorianCalendar time;
	Registrar reg;

	@Override
	protected void setUp() throws Exception {
		Properties testProps = new Properties();
		InputStream testPropStream = getClass().getResourceAsStream(
				"/motech-it-test.properties");
		testProps.load(testPropStream);
		reg = new RegistrarService(new URL(testProps
				.getProperty("motech.wsdlurl")), new QName(
				"http://motech.org/", "RegistrarService")).getRegistrarPort();
		time = DatatypeFactory.newInstance().newXMLGregorianCalendar(
				new GregorianCalendar());
	}

	@Override
	protected void tearDown() throws Exception {
		reg = null;
		time = null;
	}

	public void testRegNurse() throws Exception {
		reg.registerNurse("Gaylord", "37694676488", "A-Clinic");
	}

	public void testRegMother() throws Exception {
		reg.registerMother("37694676488", time, "CAPNCRUNCH", "Betty",
				"KFJHKF", "HDJHJDKD", 12, 313, "4674676747", time, 1, 1);
	}

	public void testRegPatient() throws Exception {
		reg.registerPatient("37694676488", "HONEYGRAHAMS", "<NAME>",
				"DHJGDJK", "HDHJHDJK", 23, Gender.MALE, 1232, "4674676747");
	}

	public void testRegPregnancy() throws Exception {
		reg.registerPregnancy("37694676488", time, "HONEYGRAHAMS", time, 2, 23);
	}

	public void testRecMaternalVisit() throws Exception {
		reg.recordMaternalVisit("37694676488", time, "HONEYGRAHAMS", 1, 1, 1,
				1, 0, 0, 0, 0, 24);
	}
}
{'fraction_non_alphanumeric': 0.12674874090654728, 'fraction_numerical': 0.0506435366536094, 'mean_word_length': 5.395348837209302, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 6}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4554223', 'n_tokens_mistral': 1479, 'n_tokens_neox': 1204, 'n_words': 263}