Blog: Testing Salesforce integrations

With Salesforce implemented and adopted to the fullest exted, the next step on the journey is to tie it together with other business critical systems. It is easy to see and understand the benefit of integrated systems, however to reach the point where your systems are actually integrated can be much harder.

[8. december 2015] Integration can be difficult but it is no different than any other development projects – it requires proper design, implementation and testing to be successful. Especially the latter is something which is lacking in many projects. In the following blog post, we will share our view on how integration test is done correctly.

As an implementation partner with and a Testing excellence center, Capgemini Danmark A/S is often helping customers getting the most out of the platform, including integration to all sorts of legacy and cloud systems, stretching from financial systems, BI platforms, and ERP business management systems to the simpler ones such as email systems, document repositories and data validation services.

Salesforce Integration Challenges

In our experience, the biggest reason for poorly designed integrations is the lack of a common system understanding. Often we see platform experts, who know every detail about a certain system, however have little or no knowledge regarding all the other systems in the company. This alone makes it hard to reach common ground of how an integration should work and operate. One could say that it is close to impossible to build a bridge, if you do not understand the shores it needs to connect. At best the result will be unstable with poor testing capabilities.

When designing a new integration, it is important to have an understanding of the whole landscape, since it defines a series of choices for how the integration should be implemented and tested, including:

  • Integration via point-to-point or middleware technology
  • Error handling – which system should handle what errors
  • Connectivity and security issues when integrating into the cloud

Apart from the above, we also encounter a series of other challenges when companies decide to integrate with Salesforce. One of them is how to handle a proper environment setup. Traditionally a software development environment cycle involves 4 different environments – Development, Integration, Staging and Production. Each serving its specific purpose in the cycle. With the pricing model from Salesforce, many companies tend to exclude one or more of these environments from their setup. Consequently integrations are often implemented directly in production as it saves time, and the production environment is the only place where real data is available for testing. However, this creates a catch 22, since doing it in production limits the possibility of testing anyway, as you shouldn’t tamper with real data. Hence, a fundamental prerequisite for doing integration correctly is to ensure proper integration and staging environments.

Another challenge is “how to test”, a common issue in regards to integration and testing is what we call “Vanilla Flow Testing”. Without a proper test approach, you only end up testing the most straightforward scenarios, hence the Vanilla flows. Instead you need to approach integration test in a more structured way. In the next section, we will give our view on how to approach this.

How to approach Salesforce integration testing

The Salesforce Testing Framework from Capgemini Danmark addresses the challenges and issues mentioned above.

First of all the approach towards the integration test is decided based on product risks, and supported by the initial product risk analysis, which is an important part of the Salesforce Testing Framework.

The Salesforce Testing Framework includes the following test types in relation to integration testing:

  • Interface evaluation
  • Interface test
  • End-2-end test

The interface evaluation assesses the documentation/definition of the interface, and can be executed at the functional and the technical levels depending on the availability of the specification document. Possible specifications for evaluating the interface between Salesforce and other systems are:

  • Information on the interface-processing function in Salesforce and the source/target system that lists at least the data elements used as well as additional informations on the way in which the interface processes data (aka protocol)
  • Information on the interface itself
  • The technical interface in intra-process interfaces which is generally realised as forms and the technical interfaces in intra-system interfaces which are often realised with files or XMLl messages.

The testing framework provides different techniques supporting the interface evaluation like different review types, checklists with most common errors in relation to interfaces.

An interface test is the dynamic test that assesses the operation of the interface. It also covers any return information if that information confirms receipt. Often, an interface test can be executed by letting the last function of Salesforce and the first function of the integrated system communicate between themselves. The interface test can be depicted like this:

It is not always (technically) feasible to start and end the interface test near the system boundaries.

As mentioned above the scope and needed effort in relation to interface testing is decided as part of the analysis of the product risks where integrations are taken into account.

As part of the testing framework different techniques supporting the interface test are provided, like process cycle test (PCT), data cycle test (DCyT), programme interface test (PIT), test charters for exploratory testing and checklists for error guessing.

The end-2-end testing is also a possible part of the testing framework for Salesforce, and it is a dynamic test intended to demonstrate that the consecutive series of systems supports the business process both internally within the company and eventually also external parties.

Closing remarks

Integrated systems are beneficial for both the business and it - by that we eventually can eliminate the redundancy of data, and by that reduce the business risks. Integrated systems also create a challenge in relation to be sure of the reliability of the information and data, and the proper test has to secure that. By using a structured test approach like the one provided with the Testing Framework for Salesforce you will have appropriate support for doing that task with insight and confidence.

todo todo
  • Søren Krabbe
    Søren Krabbe
    Managing Consultant
    +45 52189792