Salesforce is the world's first cloud-based CRM system. It was founded by Marc Benioff and Parker Harris in March 1999. The purpose of developing this CRM platform is to help users affordably and easily - sell, service, market, analyze and connect with their clients.
SFDC(Sales Force Dot Com) has many standard features which help you to manage the relationship with prospects and customers. It also allows you to engage and collaborate with employees and business partner to store their data securely in the cloud.
In this tutorial, you will learn:
- What is Salesforce?
- What is SalesForce Testing?
- Why Salesforce testing?
- Types of Salesforce Testing
- Levels of Testing in SalesForce
- Salesforce Testing Process
- Salesforce Testing challenges
- Best practice for Salesforce testing
- Roles and Responsibilities of a Salesforce Tester
- SalesForce Test Automation Tools
- Sample Salesforce Test Scenarios
- Salesforce Testing: Client Challenges
A great thing about Salesforce is that many of the out of box features can be customized to suite a company's need.
Salesforce testing is a validation of the configuration and customization performed in vanilla SDFC.
The challenge is to ensure that a tester is checking the code which has been customized in place of testing built-in salesforce functionality.
SalesForce CRM is built on a platform development language called APEX. It also provides many built in unit test case for developers to validate their code.
Here, are prime reasons behind conducting salesforce testing:
- Allows you to check that configuration and code is functional.
- Helps you to verify that the finished system can support the client's business processes
- Helps you to confirm that the system's initial build meets the agreed requirement
- Helps you to catch problems early, while they're easy to fix
- Functional flows report based on the status of test cases. This allows the team to create the functional flows to know the functionality of the application
- Process builders feature helps you to check the working condition and behavior of the system
- Workflows allow you to check the functionality of time-based events
Manual software testing process includes the testing of Salesforce.com App by using traditional methods. QA team can use manual testing can be used to execute functional testing, happy path testing, integration testing, regression testing, and system testing.
Automated testing involves a computer program to test a Salesforce.com or Force.com app. Automated testing tools like Selenium, Assure Click, QTP, etc. are used.
Following levels of Testing usually, apply to Salesforce
- Unit testing process is conducted by Apex developers. It involves writing clauses in their code which automatically tests its coverage
- It helps you to evaluates how many records of data are effected, so that the code would successfully run on in that environment.
- To deploy Apex code into a Production environment your code coverage ratio should be minimum 78%
- It Is performed by an expert team of Salesforce consultants
- Involves testing system's technical processes from beginning to finish
- Involves test script based on specific outputs
- Allows you to troubleshoot a problem with automated rules in the system like workflow, validation, assignment, etc.
- It Is conducted by the users who will use the application
- Allows to tests the system's ability to support the business processes
- UAT testing following a test script based on what happens in the business
- The desired output should be that the client confirms that the system is fit for purpose
- It is a repeat of system testing in the Production environment
- Product testing in salesforce allows you to test whether config and code have been correctly deployed from sandbox to production environment or not
- If there is time left before the final project launching, then the client should run through UAT scripts again post-deployment
- The main object of Regression testing is to test whether code and config releases is affecting existing user processes of the system
- It will be conducted once a enhancement or a fix is deployed to production.
- The user provides a list of changes which may impact their current process
The testing process of Salesforce is same as any normal web-based application. The tester should have a clear perspective of the customizable features which are built during the test process. It helps them to focus on that cutomized code instead of the built-in Salesforce features.
Developer and tester should use the Sandbox environment (Test Enriovnment) for each of their purposes. Tested code in Sandbox environment is deployed to production from the Sandbox environment. It is assumed that the QA tester has the basic knowledge and understanding of the terms used in the Salesforce.
Salesforce testing is not an easy process. There are many challenges that were faced during the process by the tester. Some of them are:
- It's not an easy task to test advanced features like Visualforce, Salesforce or Service Cloud Console.
- You need to recreate all your classic tests for the Lightning UI
- Some of the standard functionalities although not in use, can't be removed
- GUI tests don't work when we switch to the test environment
- Automated tests should able to work in all your test environments
- Issues occur while creating field locators for the Salesforce screens because some field IDs differ between Organizations
- Run tests as real user profiles
- Test Data should be prepared for validating the reports functionality
- The testing method must include functional testing, UI testing, regression testing, and system integration testing
- The dynamic nature of visual force pages should be paid special attention as all the elements of a webpage may not be loaded simultaneously
- Automation testing should be performed using tools like Selenium and HP Unified Functional Testing
- Salesforce tester should consider which include positive and negative flows
- Users role must be constructed and tested using Workflows
Important roles and responsibilities of Salesforce testers are:
- Should be able to conduct Smoke Testing to make sure all the major functionalities are functioning as per requirement
- Create both positive and negative Test Scenarios
- Able to perform equivalence Partitioning and Boundary Value Analysis
- Testers are also needed to work on the application and gain the understanding of its functionality to create functional map
- A tester should have an easy communication channel with the development team
- He should understand the customizable features which can be built for the Salesforce app
- The tester needs to execute role-based test cases to ensure the consistency of data
- He should also perform compatibility test in case Salesforce integrated with third-party applications
- A Salesforce tester should be familiar with load testing tools like JMeter to validate the complex flows which can offer inconsistent results in Salesforce
- Knowledge of Apex
Performing automated functional testing in SalesForce is a challenging task as most of the test web pages are dynamic. Therefore, the tester needs to build robust automation framework to which should be useful not only today but also in the future.
Below, given are widely used Salesforce testing tools:
- Selenium web driver
- HP Unified Functional Testing (UFT)
- Force.com IDE (Eclipse-based)
- Change Sets (Cloud Deploy)
- Ant/force.com migration tool
Reasons for using testing salesforce testing tools:
- Helps you to saves 75% of your time and 25% of your test automation costs
- Offers better Apex Test Execution, detailed test coverage, and class coverage reports
- You can take advantage of industry-leading automation tools like Selenium and JMeter.
- Auto-generate test scenarios to run for different environments and multiple browsers
- Seamlessly record and playback your recorded test cases
- Helps you to automate all types of pre- and post-deployment tasks
- Salesforce testing process separate data from test script and allows you to enhance with multiple datasets
- You can capture the contact information of the lead/client
- Contacts can be marked active/inactive
- Any company can be marked as Customer or Prospect
- Leads can be captured with the help of web forms
- Price in Quotation cannot be zero
- Email should be sent once the deal is closed. Bounced emails if any should be handled
- Integration with third party software should be working properly
- Billing services should work as expected
- No duplication of records in contact, opportunity, and lead management.
- Mobile workflow works as expected
- Unauthorized users must not have access to Files.
Clients are always nervous about Salesforce testing because they many not know how to conduct it properly. As a result, they have a myth which is very much distinct from reality.
Here, are some of them:
Don't know how to use Salesforce system.
Clients need to test their process, not the system functionality.
We can't test without all our data being present in the system.
They only need a sample records to test.
I don't have spare time to test and my daily job
They require to keep in touch with your PM and regular check-in call through the design and build stages.
- Salesforce is the world's first cloud-based CRM system
- Salesforce testing is validation the configuration and customization performed in vanilla SDFC
- Salesforce testing helps you to verify that the finished system can support the client's business processes
- The biggest challenge of SalesForce Testing is to ensure you are testing the customization and the inbuilt SDFC features
- Important Levels of Salesforce Testing are Unit Testing, System Testing, UAT Testing, Production Testing, Regression Testing
- The biggest challenge of Salesforce testing is that you need to recreate all your classic tests for the Lightning UI
- Salesforce tester should run tests as real user profiles
- Salesforce test should be able to conduct Smoke Testing to make sure all the major functionalities are functioning as per requirement
- Selenium web driver, HP Unified Functional Testing (UFT), Cucumber Force.com IDE are few important salesforce testing tools