package com.thoughtworks.selenium;

import junit.framework.*;

import org.openqa.selenium.server.*;

public class GoogleTest extends TestCase
{
   private Selenium selenium;

   public void setUp() throws Exception {
        String url = "http://www.google.com";
       selenium = new DefaultSelenium("localhost", SeleniumServer.DEFAULT_PORT, "*firefox", url);
       selenium.start();
    }
   
   protected void tearDown() throws Exception {
       selenium.stop();
   }
   
   public void testGoogleTestSearch() throws Throwable {
		selenium.open("http://www.google.com/webhp");
		assertEquals("Google", selenium.getTitle());
		selenium.type("q", "Selenium OpenQA");
		assertEquals("Selenium OpenQA", selenium.getValue("q"));
//        String s = selenium.getLogMessages();
//        assertTrue(s + " should contain type")
//        System.out.println(s);
		selenium.click("btnG");
		selenium.waitForPageToLoad("5000");
        assertTrue(selenium.isTextPresent("openqa.org"));
		assertEquals("Selenium OpenQA - Google Search", selenium.getTitle());
	}
	
}

@@ -722,18 +722,16 @@
 (%22q%22));%0A
-//
         
@@ -772,59 +772,8 @@
 ();%0A
-//        assertTrue(s + %22 should contain type%22)%0A//
     

correct getLogMessages, test it