first look at new technology (#2): testing with selenium

32
How to Test Salesforce Apps with Selenium Developers Jason Huggins: Sauce Labs, Inc. Cheryl Porro: salesforce.com Yudi Nagata: salesforce.com

Upload: salesforce

Post on 07-Nov-2014

2.049 views

Category:

Business


1 download

DESCRIPTION

Regression bugs creeping into production? Upset customers? Lost revenue? A better testing regimen can help in these situations. There are many types of testing techniques, but functional testing with Selenium can give you peace of mind that that your application works just as the user expects it to work, in the browsers they use every day.

TRANSCRIPT

Page 1: First Look at New Technology (#2): Testing With Selenium

How to Test Salesforce Apps with Selenium

Developers

Jason Huggins: Sauce Labs, Inc.Cheryl Porro: salesforce.comYudi Nagata: salesforce.com

Page 2: First Look at New Technology (#2): Testing With Selenium

Safe HarborSafe harbor statement under the Private Securities Litigation Reform Act of 1995: This presentation may contain forward-looking statements that involve risks, uncertainties, and assumptions. If any such uncertainties materialize or if any of the assumptions proves incorrect, the results of salesforce.com, inc. could differ materially from the results expressed or implied by the forward-looking statements we make. All statements other than statements of historical fact could be deemed forward-looking, including any projections of subscriber growth, earnings, revenues, or other financial items and any statements regarding strategies or plans of management for future operations, statements of belief, any statements concerning new, planned, or upgraded services or technology developments and customer contracts or use of our services.

The risks and uncertainties referred to above include – but are not limited to – risks associated with developing and delivering new functionality for our service, our new business model, our past operating losses, possible fluctuations in our operating results and rate of growth, interruptions or delays in our Web hosting, breach of our security measures, the outcome of intellectual property and other litigation, risks associated with possible mergers and acquisitions, the immature market in which we operate, our relatively limited operating history, our ability to expand, retain, and motivate our employees and manage our growth, new releases of our service and successful customer deployment, our limited history reselling non-salesforce.com products, and utilization and selling to larger enterprise customers. Further information on potential factors that could affect the financial results of salesforce.com, inc. is included in our annual report on Form 10-K for the most recent fiscal year ended January 31, 2010. This documents and others are available on the SEC Filings section of the Investor Information section of our Web site.

Any unreleased services or features referenced in this or other press releases or public statements are not currently available and may not be delivered on time or at all. Customers who purchase our services should make the purchase decisions based upon features that are currently available. Salesforce.com, inc. assumes no obligation and does not intend to update these forward-looking statements.

Page 3: First Look at New Technology (#2): Testing With Selenium

The Problem – So Many Platforms to test!

Page 4: First Look at New Technology (#2): Testing With Selenium

The Solution – Needs to Be Automated…

Source: - F.O.X.: http://www.flickr.com/photos/kv/499219/

Page 5: First Look at New Technology (#2): Testing With Selenium

…And Can Deal with Ajax…

Page 6: First Look at New Technology (#2): Testing With Selenium

…And Verify End-to-End Workflows.

Page 7: First Look at New Technology (#2): Testing With Selenium

Selenium

Page 8: First Look at New Technology (#2): Testing With Selenium

Selenium IDE for Firefox

Page 9: First Look at New Technology (#2): Testing With Selenium

“Selenese”

Page 10: First Look at New Technology (#2): Testing With Selenium

Remote Control

Page 11: First Look at New Technology (#2): Testing With Selenium

Example Selenium RC Test – Java

Page 12: First Look at New Technology (#2): Testing With Selenium

Selenium Remote Control Architecture

Page 13: First Look at New Technology (#2): Testing With Selenium

Time

Servers

Unit of Work

Page 14: First Look at New Technology (#2): Testing With Selenium

Time

Servers

Unit of Work

Page 15: First Look at New Technology (#2): Testing With Selenium

Selenium Grid

Page 16: First Look at New Technology (#2): Testing With Selenium

Sauce Labs

Page 17: First Look at New Technology (#2): Testing With Selenium

Sauce Labs

• Cloud-hosted Selenium for:

• Speed—run tests in parallel

• Pain-free infrastructure (test infrastructure is notoriously fussy, fiddly

due to accelerating Browser numbers and version pace, security

patches etc.)

• Higher availability, repeatability

• Commercial Support for Selenium

Page 18: First Look at New Technology (#2): Testing With Selenium

Sauce OnDemand (just like Se Grid)

Page 19: First Look at New Technology (#2): Testing With Selenium

Demo!

Page 20: First Look at New Technology (#2): Testing With Selenium

How to Avoid Selenium Poisoning

Page 21: First Look at New Technology (#2): Testing With Selenium

Intent Action

Page 22: First Look at New Technology (#2): Testing With Selenium

Action

open 'www.example.com'

clickAndWait 'link=Log in'

type 'User Id', '[email protected]'

type 'password', '12345678'

clickAndWait 'Log In'

Page 23: First Look at New Technology (#2): Testing With Selenium

Intent

Log in

Change password

Modify profile

Log out

Page 24: First Look at New Technology (#2): Testing With Selenium

Hudson

Ant/NAnt

xUnit

Selenium

The Really Good “Stack”

Page 25: First Look at New Technology (#2): Testing With Selenium

Business Specific Library

Hudson

Ant/NAnt

xUnit

Selenium

The Ideal “Stack”

Page 26: First Look at New Technology (#2): Testing With Selenium

Page Object Model

Page 27: First Look at New Technology (#2): Testing With Selenium

Start Small

Page 28: First Look at New Technology (#2): Testing With Selenium

It’ll Get Big Anyway

Page 29: First Look at New Technology (#2): Testing With Selenium

What to Start With?

Smoke tests

“Money path”

New features

Page 30: First Look at New Technology (#2): Testing With Selenium

Benefits of Short Tests

Easier to read

Easier to write

Easier to debug/maintain

Easier to parallelize

Page 31: First Look at New Technology (#2): Testing With Selenium

Find Out More!

http://sauceforce-developer-edition.na1.force.com/

http://code.google.com/p/apexselenese/

http://code.google.com/p/sauceforce/

http://code.google.com/p/testcloudconfigurator/

http://seleniumhq.org

http://saucelabs.com

Page 32: First Look at New Technology (#2): Testing With Selenium

How Could Dreamforce Be Better? Tell Us!

Log in to the Dreamforce app to submit

surveys for the sessions you attendedUse the

Dreamforce Mobile app to submit

surveysEvery session survey you submit is

a chance to win an iPod nano!

OR