2. Background
Tools
Past
Challenges
“The
Decision”
Benefits
Conversion
Present
Examples
3. Custom
framework
written
in
Java
In
house
test
management
system
TestElements
▪ Projects
▪ Test
Suites
Test
Cases
Actions
Data
Elements
Object
Store
Fully
integrated
with
our
Framework
4. Eclipse
IDE
TestElements
Results
Viewer
+
iPad
version
SauceLabs
SeleniumIDE
Firebug
Ivy
Git
-‐
version
control
5. Selenium
1
&
Selenium
Grid
6
lab
machines
▪ Mac’s
and
PCs
with
different
browser
combinations
RC
for
each
desired
browser
on
local
machines
RC
for
each
desired
browser
on
each
remote
machine
running
on
SeleniumGrid
6. Maintenance
of
RC’s
If
1
RC
had
an
issue,
must
kill
all
RC’s,
restart
HUB,
and
restart
each
one
again
>
800
test
cases
executed
amongst
6
machines
multiple
times
a
day
▪ (approx.
2500/day)
Parallel
execution
was
challenging
Cross
browser
testing
7. Solved
every
challenge
on
the
list
Selenium
RC’s
in
the
cloud
No
maintenance
Video
Replaced
Selenium
with
WebDriverBackedSelenium
Selenium
1
backwards
compatible
New
code
would
use
WebDriver
8. WebDriverBackedSelenium
on
Sauce
Each
selenium
1
command
would
spit
back
javascript,
causing
very
slow
test
execution
times
WebDriver
commands
were
OK
Did
not
realize
this
right
away
Santiago
the
‘Sauce
Ninja’
9.
10. Convert
EVERYTHING…
No
more
XPATH!
CSS_SELECTOR
▪ Native
support
on
each
browser
ID
LINK_TEXT
11. Improve
execution
speed
on
Sauce
(no
more
JavaScript)
Better
emulation
of
user
interactions
Better
API
–
More
object
oriented
Stability
Improve
logic
in
codebase
Don’t
want
to
be
left
behind
New
version
of
Selenium
all
the
time
Bug
fixes,
improvements
Feel
they
care
about
the
product
Fun
12. Line
by
Line
conversion
remove
any
selenium1
references
Not
enough
documentation
existed
Not
everything
appeared
to
be
easily
converted
hover
/
mouseOver
select
from
combo
box
attachFile
13. Different
functionality
Objects
must
be
visible
before
acting
on
them
Type
mechanism
does
not
clear
the
text
field
before
filling
it
out
*
changed
in
2.6
Selenium2
is
blocking
▪ No
more
waitForPageToLoad(….)
Use
ExpectedCondition
class
to
wait
for
presence
/
visibility
of
element
Different
names
no
more
isElementPresent
/
isVisible
14. Simplify
codebase
Find
Selenium2
conversion
for
everything
and
create
wrapper
in
our
Framework
SeleniumBase.java
was
born
Custom
WebDriver
commands
All
scripts
extend
from
this
class
Less
clutter
Maintainability
21. List<WebElement> productLookTitleAll =
getWebElements(LocatorType.CSS_SELECTOR,"Gilt Product Listing Page","Product Look Title Links");
List<WebElement> productLookTitleAvailable =
getWebElements(LocatorType.CSS_SELECTOR,"Gilt Product Listing Page","Available Product Look Title Links");
List<WebElement> productLookSoldOut =
getWebElements(LocatorType.CSS_SELECTOR,"Gilt Product Listing Page","Sold Out Product Look Title Links");
22. 99.9999%
converted
to
Selenium2
▪ attachFile()
Stable
results
Clean,
easy
to
manage
code
SeleniumBase
continues
to
grow
Ivy
to
manage
dependencies
Upgrade
to
Selenium
2.x
quickly
Push
changes
to
team
through
Git
23. Make
the
switch
Spread
the
work
out
to
save
time
Be
aware
of
the
differences
b/t
Sel1
and
Sel2
More
documentation
Modularize
common
selenium
commands
Selenium
Users
google
group