LEAPWORK_Selenium for Salesforce Automation
LEAPWORK_Selenium for Salesforce Automation
Salesforce Automation
Everything you need to decide if Selenium is the tool
for your Salesforce test automation needs
Table of contents
3 Introduction
5 What is Selenium?
5 A short history of Selenium
7 The Selenium tool suite
9 The advantages of Selenium
10 The disadvantages of Selenium
Selenium thus became the first tool that enabled its users to control a
browser using any programming language.
Selenium RC
Over the past 20-30 years we’ve Imagine if a bug in Amazon’s pricing
seen a massive transformation in how system meant that products were
technology is used with businesses being offered at a significantly
becoming completely on software lower or higher price. Sales would
systems to operate. Software testing either drop or skyrocket with no
is key to enabling fast and error-free return, and the business would suffer
software and ensures that businesses tremendously.
can deliver what end-users expect
This is just an example, but there are
from products and services.
countless real world examples of
A few examples of businesses that businesses that have lost millions due
depend on web applications to deliver to improper software testing.
their products and services include
So how do these companies avoid
Amazon, Airbnb, and Netflix.
dangerous glitches like these? They
How would these businesses run if it test their software to lower risk.
weren’t for internet systems? What
would happen if there was a flaw in
their systems?
Selenium IDE
Selenium IDE is a ‘record and playback tool’ that can
help you create and edit test cases and test suites. IDE
(Integrated Development Environment) is a Chrome and
Firefox plugin that is used to create and execute test cases.
It lets you create test cases by recording your interactions
with the browser. Your interactions are ‘transformed’ into
steps in Selenium’s own language. These steps can then be
exported in different programming languages, including
Java, Python and Ruby, that can then be executed later.
The result is the entire test script in your language of
choice.
Selenium WebDriver
Selenium WebDriver is a programming interface that
can be used to create and execute test cases. WebDriver
allows you to test across all the major programming
languages, browsers, and operating systems.
Selenium Grid
Selenium Grid allows you to run multiple tests at the same
time on multiple machines, also known as parallel testing.
First, Selenium only allows you to test web applications – not mobile
or desktop. Useful functionalities such as reporting, and data-driven
testing are only possible with the integration of additional tools. In
other words, Selenium is in no way an ‘all-in-one’ platform.
Aside from setting up and maintaining the script, you’ll also need to
make sure that your code ‘speaks’ with the rest of the release pipeline.
This means that as a tester need to know the code versioning used in
your Git repository.
There are a vast number of tools and testing frameworks available for
test automation, and there might be a tool that serves your needs in
Salesforce better than Selenium.
If you decide to explore other options, here are a few features that you
should consider with your team’s and business’ needs in mind:
Is it collaborative,
Is it visual, providing you
allowing your team to
with a good overview of
work together on the
your test suite?
software?
On top of that, Selenium isn’t exactly an intuitive tool, and you can’t
get any 1:1 support. You must either take a course in Selenium, have a
go at Selenium’s user documentation, reach out to the community for
answers, or take a good old-fashioned learning-by-doing approach.
For the tester, this means simplifying the testing process of creating
testing scenarios by replacing written scripts with visual building
blocks. For the developer, this means speeding up the entire process,
and letting them focus on software development and innovation.
With a test automation tool that hides the code behind the scenes and
only shows the most necessary actions and steps up front, the tester
can more easily maintain scripts, as they’ll have a clearer overview of
the steps and can detect if changes need to be made...
Use the Selenium column to see what Selenium can and cannot do
and compare it to the Leapwork column to find out if a no-code
platform might be a better solution for you.
Requires a vast understanding of the Its locator strategy allows dynamic web
Executing against Salesforce DOM, Parent-Child, and elements to be efficiently identified,
dynamic content Root-Ancestor hierarchies. with the option to tweak or change the
chosen strategy as required.
A lot of effort is needed to support The same use case can be executed
data-driven testing. For example, using for multiple Salesforce users with input
Driving data Excel requires writing functions and from spreadsheets, databases, and
parameterizing to avoid hard coded web services.
values in your scripts.
While you can always re-use parts of Tests can run smoothly despite frequent
an existing Selenium script, figuring updates, thanks to reusable cases,
Reusability out how to save, name, maintain, and visual debugging capabilities, and
share this work is complex and time- video-based reporting.
consuming.
Can only be used by programmers, Can do the exact same thing with easy-
who get low-level access to browser to-use building blocks, and without
Programming behavior and actions through using any having to read or write a single line of
needed programming language (C#, Java, code. Perfect for non-technical users
Python, PHP, etc). – or anyone who just doesn’t want to
spend time on programming.
Uses highly complex CSS or XPath Point and click to capture any web
Finding web “selectors”, which require deep technical element. Smart algorithms then
elements knowledge. automatically find the best way to
locate it again in the future.
Typically takes 3-6 months for an initial Max. 3 months, using a structured
Speed of
project, then another 6-12 months for learning and on-boarding program.
adoption
framework programming.
Locked,
Not available Available
tamper-proof flows
An object repository is not included, but All assets such as web element locators
programmers can custom-build their and flows are structured and stored in
own and decide on implementing code an encrypted database with built-in
patterns such as Page Object Model. version history.
Object repository
and version history
Version history can be achieved using
source control systems such as Git,
which most non-technical users find
impossible to navigate.
Any CI/CD platforms can be used All popular CI/CD platforms can easily
by custom-built solutions. A good be integrated by DevOps using plugins
Built-in CI/CD
ecosystem and lots of code samples or the REST API.
plugins
exist on the internet for professional
programmers to use.