#!/usr/bin/env python
# -*- coding: utf-8 -*-

#-----------------------------------------------------------------------------
# Copyright 2013 Carona Sustentavel
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program.  If not, see <http://www.gnu.org/licenses/>
#-----------------------------------------------------------------------------

import unittest
from selenium import webdriver


class Selenium2OnSauce(unittest.TestCase):

    def setUp(self):
        desired_capabilities = webdriver.DesiredCapabilities.CHROME
        desired_capabilities['version'] = ''
        desired_capabilities['platform'] = 'Windows 2003'
        desired_capabilities['name'] = 'Testing Selenium 2 in Python at Sauce'

        self.driver = webdriver.Remote(
            desired_capabilities=desired_capabilities,
            command_executor="http://andremontoiab:d95e5825-a4d4-4a27-9b6e-3b899f5b09e1@ondemand.saucelabs.com:80/wd/hub"
        )
        self.driver.implicitly_wait(30)

    def test_sauce(self):
        self.driver.get('http://carona-sustentavel.rhcloud.com/')
        self.assertTrue("I am a page title - Sauce Labs" in self.driver.title)
        comments = self.driver.find_element_by_id('comments')
        comments.send_keys('Hello! I am some example comments.')
        self.driver.find_element_by_id('submit').click()

    def tearDown(self):
        print("Link to your job: https://saucelabs.com/jobs/%s" % self.driver.session_id)
        self.driver.quit()

if __name__ == '__main__':
    unittest.main()
@@ -1594,25 +1594,24 @@
 d.com/')
-%0A
         
 self.ass
@@ -1606,95 +1606,121 @@
     
-self.assertTrue(%22I am a page title - Sauce Labs%22 in self.driver.title)%0A        comments
+%0A        comments = self.driver.find_element_by_id('deformField1')%0A        comments.send_keys('test')%0A%09%09comments2
  = s
@@ -1750,24 +1750,28 @@
 _by_id('
-comments
+deformField2
 ')%0A     
@@ -1773,32 +1773,33 @@
         comments
+2
 .send_keys('Hell
@@ -1798,42 +1798,13 @@
 ys('
-Hello! I am some example comments.
+11111
 ')%0A 
@@ -1838,18 +1838,20 @@
 ment_by_
-id
+type
 ('submit

Update tests