Example #1
0
 def test_placeholder(self):
     self.driver.get(self.base_url + '/index.html#/form')
     input_el = Input(self.driver, "appCtrl.placeHolder", "model")
     self.assertEqual(input_el.get_placeholder(), u'Last name')
Example #2
0
 def test_clear(self):
     self.driver.get(self.base_url + '/index.html')
     input_el = Input(self.driver, "appCtrl.textFieldFull", "model")
     input_el.clear()
     self.assertEqual(input_el.get_value(), u'')
Example #3
0
 def test_set_value(self):
     self.driver.get(self.base_url + '/index.html')
     input_el = Input(self.driver, "appCtrl.textField", "model")
     input_el.set_value(u'Test')
     self.assertEqual(input_el.get_value(), u'Test')
Example #4
0
 def test_send_keys(self):
     self.driver.get(self.base_url + '/index.html')
     input_el = Input(self.driver, "appCtrl.textFieldFull", "model")
     input_el.send_keys(" Test")
     self.assertEqual(input_el.get_value(), u'Hello World Test')
Example #5
0
 def test_clear(self):
     input_el = Input(self.driver, "//input[@ng-model='username']")
     input_el.clear()
     self.assertEqual(input_el.get_value(), u'')
Example #6
0
 def test_get_element_type_element(self):
     self.driver.get(self.base_url + '/index.html')
     input_el = Input(self.driver, "appCtrl.textField", "model")
     self.assertEqual(input_el.element_type, 'input_type')
Example #7
0
 def test_placeholder(self):
     input_el = Input(self.driver, "//input[@ng-model='username']")
     self.assertEqual(input_el.get_placeholder(), u'Username')
Example #8
0
 def test_send_keys(self):
     input_el = Input(self.driver, "//input[@ng-model='username']")
     input_el.send_keys("Test")
     self.assertEqual(input_el.get_value(), u'AnonTest')
Example #9
0
 def test_set_value(self):
     input_el = Input(self.driver, "//input[@ng-model='username']")
     input_el.set_value(u'Test')
     self.assertEqual(input_el.get_value(), u'Test')
Example #10
0
 def test_get_value(self):
     input_el = Input(self.driver, "//input[@ng-model='username']")
     self.assertEqual(input_el.get_value(), u'Anon')
Example #11
0
 def test_get_element_type_element(self):
     input_el = Input(self.driver, "//input[@ng-model='username']")
     self.assertEqual(input_el.element_type, 'input_type')