def test_login_3(self):
		h = "z"
		u = "lucascf"
		p = "Lrk9S1IA91"
		d = "cs327e_lucascf"
		out=login(h, u, p, d)
		self.assertTrue(str(type(out)) == "<type '_mysql.connection'>")
	def test_login_1(self):
		h = "z"
		u = "abatista"
		p = "TCgfNXdb.p"
		d =  "cs327e_abatista" 
		out=login(h, u, p, d)
		self.assertTrue(str(type(out)) == "<type '_mysql.connection'>")
	def test_login_2(self):
		h = "z"
		u = "ofac90"
		p = "MMVAIRmfJ6"
		d = "cs327e_ofac90"
		out=login(h, u, p, d)
		self.assertTrue(str(type(out)) == "<type '_mysql.connection'>")
	def test_importToSql_3(self):
		string="""<root><crises>
        <crisis>
            <crisisId>CRI_003</crisisId>
            <name>Great Depression in US</name>
			<kind>Human Error Disaster</kind>
            <streetAddress></streetAddress>
            <city></city>
            <stateOrProvince></stateOrProvince>
            <postalCode></postalCode>
            <country>USA</country>
            <dateAndTime>1929-10-29T00:00:00</dateAndTime>
            <fatalities>40000</fatalities>
            <injuries>0</injuries>
            <populationIll>0</populationIll>
            <populationDisplaced>200000</populationDisplaced>
            <environmentalImpact></environmentalImpact>
            <politicalChanges>New Deal, Increased Size of Government, creation of the Securities and Exchange Commission (SEC) and the Federal Deposit Insurance Corporation (FDIC)</politicalChanges>
            <culturalChanges>Generaton that lived through the Great Depression stayed frugal, wary of banks, and suspicious of the stock market</culturalChanges>
            <jobsLost>11000000</jobsLost>
            <damageInUSD>0</damageInUSD>
            <reparationCost>160000000</reparationCost>
            <regulatoryChanges>Strict trading and banking regulations</regulatoryChanges>
        </crisis>
	</crises></root>"""

		inputstr = fromstring(string)
		c = login()
		create(c)
	        importToSQL(inputstr)
		t = query(
		c, 
		"select country from crises where country='USA';")
		self.assertTrue(str(t[0][0]) == str('USA'))
	def test_create_3(self):
		h= "z"
		u = "abatista"
		p = "TCgfNXdb.p"
		d = "cs327e_abatista"
		c = login(h, u, p, d)
		create(c)
		t = query(
		c, 
		"select * from people")
		self.assertFalse(t is None)
 def test_login_1(self):
     self.assertTrue(str(type(login()) == "<type '_mysql.connection'>"))
 def test_login_1(self):
     self.assertTrue(str(type(login()) == "<type '_mysql.connection'>"))
 def test_query_3(self):
         c = login()
         create(c)
         t = query(c, "select * from crises;")
         self.assertTrue(str(type(t)) == "<type 'tuple'>")
 def test_query_2(self):
         c = login()
         create(c)
         t = query(c, "show tables;")
         self.assertTrue(str(type(t)) == "<type 'tuple'>")
 def test_query_1(self):
         c = login()
         t = query(c, "show Databases;")
         self.assertTrue(str(type(t)) == "<type 'tuple'>")