*{ You can use plain selenium command using the selenium tag }* #{selenium} clearSession() // Open the home page, and check that we are redirected to the login page open('/') assertTitle('Sign in') // Forget the nickname clickAndWait('enter') assertTextPresent('Please give a nick name') // Login as Bob type('nick', 'Bob') clickAndWait('enter') // We are now in the chat room assertTextPresent('You are now chatting as Bob') type('message', 'Hello !') click('send') // Wait the message waitForTextPresent('Hello !') // Hop two more messages type('message', 'Im bob !') click('send') pause(3000) type('message', 'Anyone here ?') click('send') pause(3000) // Wait the message waitForTextPresent('Im bob !') waitForTextPresent('Anyone here ?') // Leave the room clickAndWait('link=*Leave*') assertTitle('Sign in') #{/selenium}