0% found this document useful (0 votes)
193 views27 pages

Salesforce Testing Basics and FAQs

Uploaded by

archvivek.mishra
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
193 views27 pages

Salesforce Testing Basics and FAQs

Uploaded by

archvivek.mishra
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 27

Salesforce

Testing
Basics And
FAQs

By Rupendra Ragala
What is Salesforce
Testing?
Salesforce Testing is the process of
validating the configurations and
functionalities of the Salesforce CRM
platform based on business requirements.
It ensures that customizations,
integrations, and built-in features work
as expected without breaking existing
functionality.
What is Salesforce?
Salesforce is a cloud-based Customer
Relationship Management (CRM) platform
widely used for sales, service,
marketing, analytics, and application
development.
It includes both out-of-the-box
functionalities and custom-developed
applications using Apex (code) and
Visualforce (UI), along with
configurations done via point-and-click
tools.
Key Objectives of
Salesforce Testing

Validate standard functionalities


(Leads, Opportunities, Accounts,
etc.)
Verify custom features and workflows
Ensure data accuracy and integrity
Test integration with external
systems (like ERP, payment systems,
etc.)
Validate security roles and profiles
Test updates from Salesforce
seasonal releases
Perform regression testing after any
configuration/code changes
Key Topics to Understand
in Salesforce Testing

1. Salesforce Basics: Understand


objects (Standard & Custom), fields,
relationships, tabs, page layouts,
record types
2. Salesforce Data Model: Entity
relationships, schema design, master-
detail, and lookup relationships
3. Standard vs. Custom Objects:
Understand standard features vs
custom-built functionality
4. Apex & Visualforce: Basic
understanding of code-based
customizations
5. Lightning Components: Test UI built
with Lightning Web Components (LWC)
Key Topics to Understand
in Salesforce Testing

6. Validation Rules & Workflows:


Ensure rules trigger correctly and
data is validated
7. Process Builder & Flow: Test
business automation logic and flows
8. Security Testing: Validate role-
based access control, profiles,
permission sets, FLS (Field-Level
Security)
9. Integration Testing: Validate APIs
(REST/SOAP), middleware systems,
external data loads
10. Data Migration Testing: Test data
loading using tools like Data Loader,
Import Wizard, and validate integrity
Key Topics to Understand
in Salesforce Testing

11. Reports and Dashboards: Validate


KPIs, filters, aggregation, and data
accuracy in reports
12. Sandbox & Release Management:
Understand org types (Developer,
Sandbox, Production) and deployment
lifecycle
13. Regression & UAT Testing: Ensures
existing features work after updates
14. Automation Testing: Tools like
Selenium, Provar, ACCELQ, Tosca for
automating Salesforce tests
15. Salesforce Release Testing:
Salesforce has 3 major releases a year
—test for impact of these upgrades
Salesforce Testing Types

Unit Testing (Apex code)


Functional Testing
Integration Testing
Regression Testing
System Testing
UAT (User Acceptance Testing)
Load & Performance Testing (for
large data volumes)
Common Tools Used

Selenium – for browser-based UI


testing
Provar – Salesforce-specific
automation tool
Testim / ACCELQ / Tosca – for
codeless or low-code Salesforce
automation
JIRA – for bug tracking
Postman – for API testing
Salesforce Tester
Responsibilities

Understand Salesforce features &


modules
Write & execute test cases for
standard and custom modules
Validate reports, dashboards, and
automation flows
Perform cross-browser testing
Verify security (profiles,
permission sets, etc.)
Collaborate with admins,
developers, and business users
Salesforce Testing
Lifecycle

Understand Salesforce features &


modules
Write & execute test cases for
standard and custom modules
Validate reports, dashboards, and
automation flows
Perform cross-browser testing
Verify security (profiles,
permission sets, etc.)
Collaborate with admins,
developers, and business users
Common Salesforce
Modules to Test

Sales Cloud - Lead conversion,


opportunity pipeline, forecast
validation
Service Cloud - Case assignment,
email-to-case, SLA management
Marketing Cloud - Campaign
execution, email triggers,
journey builder workflows
Community Cloud -Partner/customer
access, content sharing,
permissions
Einstein Analytics - Report
filters, datasets, dashboards
Custom Apps - Any custom-built
Lightning App, Apex class, or
flow
Real-Time Testing
Scenarios

Lead Validation Rule: Test that a


Lead cannot be saved without a phone
number if the country is "US".
Opportunity Stage Change: Validate
automation when stage changes to
"Closed Won" (e.g., generate a
contract or invoice).
Approval Process: Submit a case for
approval and ensure it moves to the
right manager based on region.
Email Notification: Verify that an
email is triggered to the customer
when a Case is closed.
Data Uploads: Load 5000 Contacts
using Data Loader and ensure mapping &
data quality.
API Integration: Test a REST API that
sends customer info from Salesforce to
an external billing system.
Challenges in Salesforce
Testing

Frequent Releases - Salesforce


releases 3 times/year — regression
testing is mandatory
Dynamic UI - Lightning Web
Components (LWC) can be hard to
automate
Limited Access - Admin-only areas
may limit QA testers without
proper roles
Test Data Issues - Large datasets
are often masked or missing in
lower environments
Complex Integrations - Multiple
systems (ERP, payment gateways,
legacy apps)
Salesforce Security
Testing Key Areas

Profiles & Roles - Users should


access only permitted
objects/records
Sharing Rules - Ensure proper data
visibility and hierarchy sharing
Field-Level Security - Sensitive
fields hidden based on profiles
Login & IP Restrictions - Access
control by location/time/user
Session Settings - Timeouts,
reauthentication, etc.
Permission Sets - Check overrides
and access privileges
FAQS
What is Salesforce Testing?
Salesforce Testing involves validating the
configuration and customization of the
Salesforce application. This includes
testing Apex classes/triggers, Visualforce
pages, Lightning components, workflows,
validation rules, and integrations to
ensure they meet business requirements.
What is a Sandbox in Salesforce?
A sandbox is a replica of the production
environment used for development, testing,
and training without affecting live data.
Types include Developer, Developer Pro,
Partial Copy, and Full Sandbox.
What is Apex?
Apex is a strongly-typed object-oriented
programming language used by Salesforce
developers to write business logic such as
triggers, classes, and web services.
FAQS
What is a Validation Rule?
It ensures data integrity by preventing
users from entering invalid data. It
contains a formula that returns true/false
and displays an error message.
What is the difference between Standard
and Custom Objects?
Standard Objects are provided by
Salesforce (e.g., Lead, Account).
Custom Objects are user-defined to
store data unique to a business.
Explain SOQL vs SOSL
SOQL (Salesforce Object Query Language)
retrieves records from a single object.
SOSL (Salesforce Object Search
Language) searches text across multiple
objects.
FAQS
How do you perform functional testing in
Salesforce?
Test end-to-end flows like Lead to
Opportunity conversion, Approval
Processes, and Record Updates by
simulating user actions through the UI or
APIs.
What is a Trigger in Salesforce?
A Trigger is an Apex script that executes
before or after a record is inserted,
updated, or deleted.
What is Code Coverage in Salesforce?
It's a measure of how much of the Apex
code is executed during testing.
Salesforce mandates 75% code coverage for
deployment to production.
Which tools are commonly used in
Salesforce Testing?
Selenium, Provar, Testim, Postman, Data
Loader, Salesforce Inspector, Workbench.
FAQS
Can you automate Salesforce Testing with
Selenium?
Yes, but it's complex due to dynamic
elements in Lightning components. Tools
like Provar or Testim are better suited
for Salesforce-specific automation.
What is Provar?
A test automation tool designed for
Salesforce. It provides built-in support
for Salesforce components, making testing
faster and more reliable.
What is API Testing in Salesforce?
Validating the REST/SOAP APIs for
integration between Salesforce and
external systems. Tools like Postman are
used for this.
How would you test a REST API in
Salesforce?
Authenticate using OAuth
Send a request (GET/POST/PUT/DELETE)
Validate the response code and body
Confirm data consistency via UI
FAQS
What is Data Loader and how is it used?
A Salesforce tool to insert, update,
delete, or export data in bulk. Useful for
test data setup and validation.
What is Change Set?
A set of components (Apex classes,
workflows, etc.) deployed from one
Salesforce org to another (e.g., Sandbox
to Production).
How do you perform Integration Testing in
Salesforce?
Identify touchpoints between Salesforce
and other systems
Use API logs and debug logs
Validate incoming/outgoing data and
error handling
How do you test Scheduled Jobs in
Salesforce?
By triggering jobs using Test.startTest()
and Test.stopTest() in Apex test classes
and verifying the result.
FAQS
What are Governor Limits in Salesforce?
Runtime limits enforced by Salesforce to
ensure efficient use of resources. E.g.,
SOQL queries, CPU time, DML operations.
What is Profile and Role in Salesforce?
Profile defines object/field-level
access.
Role defines record-level access via
role hierarchy.
What is Field-Level Security?
Controls visibility of fields for
different profiles. Testers must ensure
sensitive fields are hidden where
necessary.
What is Sharing Rule?
Determines how records are shared across
users or roles. Validate that sharing
behaves as configured.
FAQS
What is Permission Set?
Grants additional permissions to users
without changing their profile.
What is Lightning Web Component (LWC)?
A UI framework for building modern
Salesforce components. UI tests must
validate interactivity, dynamic behavior,
and accessibility.
How do you test Visualforce Pages?
Validate input/output behavior, ensure
Apex controllers are linked properly, and
test rendering on different browsers.
What are some UI Testing Challenges in
Salesforce?
Dynamic DOM in Lightning
Shadow DOM in LWC
Complex navigation
Custom modals/dialogs
FAQS
What is the difference between Page Layout
and Record Types?
Page Layout controls fields/sections
visible on the UI
Record Type determines available
picklist values and layout for a record
What is an Approval Process and how do you
test it?
Automated flow for record approvals. Test
by submitting a record, checking the
approver, rejection paths, and
notifications.
How do you validate Email Alerts in
Salesforce?
Trigger the event (e.g., Case Closed),
monitor emails using test addresses or
delivery logs, and verify format/content.
What is UAT in Salesforce?
Final phase of testing performed by
business users to ensure the system meets
their needs.
FAQS
Give examples of real-world Salesforce
test scenarios.
Convert a Lead to Opportunity
Trigger workflow on Case creation
Validate Revenue Rollup on Opportunity
Closed-Won
How do you perform regression testing in
Salesforce?
Re-run automation/manual test cases after
deployments or Salesforce seasonal
releases.
How do you validate Reports and
Dashboards?
Check filters and grouping
Validate aggregated data
Test visibility based on roles
What is a Custom Setting and how do you
test it?
A way to store configuration data. Test by
changing values and validating impact in
logic.
FAQS
What is Custom Metadata Type?
Like custom settings but deployable via
metadata API. Test impacts on logic,
especially in Apex.
How do you test Record Types in
Salesforce?
Create records using different record
types and validate applicable picklists,
layouts, and business logic.
What is Dynamic Form and how do you test
it?
Dynamic layout based on user input. Test
by triggering changes and validating field
visibility or behavior.
What are Flows in Salesforce and how are
they tested?
Declarative automation. Trigger flows
through UI/API and verify outcomes, data
updates, and branching.
FAQS
What is Debug Log and how do testers use
it?
Captures system-level logs. Testers use it
to debug Apex, workflows, and
integrations.
What is @testSetup in Apex?
Used to create reusable test data for
multiple test methods in a class.
What is Test.startTest() and
Test.stopTest()?
These simulate test execution boundaries,
used to test asynchronous processes and
governor limits.
What are the best practices for writing
test classes?
Cover all code paths
Avoid hardcoded IDs
Use assertions
Use SeeAllData=false
FAQS
How do you handle seasonal Salesforce
releases?
Read release notes
Test affected components in Sandbox
Perform regression testing
What is Test Coverage and how to improve
it?
Ensuring code is tested by unit tests. Use
multiple scenarios and mock data to
increase coverage.
How do you manage Test Data in Salesforce?
Use @testSetup, Data Loader, Factory
classes, or pre-configured records in
Sandbox.
What is a CI/CD pipeline in Salesforce
testing?
Automates code integration and testing
using tools like Git, Jenkins, and
Salesforce DX.
If you find
this helpful,
like and share
it with your
friends
Thanks you -
Rupendra Ragala

You might also like