What features did we miss in Salesforce Spring ’17 release?
August 18, 2017

What features did we miss in Salesforce Spring ’17 release?

Previous releases of Salesforce were really cool. Take, for example, Lightning Experience for service or Commerce Insights. But there were other valuable features geared to developers that received too little attention even in release notes. Some features got lost among updates to Wave, Einstein and new admin features. Our senior Salesforce expert shares his insights on these awesome functionalities.

Apex Stub API – generally available since Spring ’17

Stub API makes testing easier by implementing mocking framework. Mocks are a powerful tool for Unit Testing.  For example, Mockito and other libs for Java enable true Unit Testing. Now, when building a mocking framework with the stub API, the stub objects are generated dynamically, so there is no need to package and deploy test classes.  As a result, you can either build your own mocking framework or make use of the one built by someone else.


Imagine you are testing some functionality that intersects with others, thus starting quite complex and intricate processes. With mocking framework, this functionality does not trigger long-term running processes, and the developer can test a specific feature without interfering with all the others involved.

The concept is great, but Apex Stub API has its drawbacks.  For example, mocks have been available for apex development since the lib delivered by FinancialForce (https://github.com/financialforcedev/fflib-apex-mocks), but due to difficulties in implementation and limitations of usage, Stub API seemed like a better solution.  What we received instead is something very similar to the lib in FinancialForce, and is even more limited at times, e.g., static, private, get/set, methods from triggers, inner classes, batchable, system types and singletons are not allowed. Unfortunately, these limitations diminish the value of Stub API because most of the big logic components are stored that way.


  • Idea – A, Implementation – F
  • Limits need to be improved  

Lightning:container – developer preview since Spring ’17

Content is hosted in an iFrame by the lightning:container component. It enables communication to and from the framed application and thus interacts with the Lightning component.


Finally, you can store apps directly in Salesforce without using external hosting!

It extends Lightning framework which is limited by default with the help of other frameworks. For example, it provides the ability to host JavaScript frameworks, such as modern React and apps inside Lightning components.  Without limitations that are present in VisualForce, it allows the use of  various directories.

The idea looks promising, although you still can experience some limitations in iFrame. There could be some minor issues with scrolling, caching, etc. It seems like a canvas app, but now it is hosted inside SFDC, which is a great plus.


  • Idea – A, implementation – B
  • Fingers crossed for this to be released as it is in Developer Preview
  • Limits need to be improved
  • N.B. Content Security Policy can be less strict than in Lightning Framework, which allows us to use lots of javascript libs that had been banned due to security policy for Lightning, e.g., inline javascript and eval are banned due to this.

Senior Salesforce Engineer, CoreValue




Recent Articles

How to Build the Best Medical Mobile App

January 9, 2019

Time is a vital issue nowadays and we can not afford wasting it. That is why we order things online and keep most of our important information on our smartphones. Healthcare services are also available at your fingertips today. According to the IQVIA institute for Human Data Science, there are more than 318,000 medical or […]

CoreValue is Top Web and Software Development Company in 2018

January 2, 2019

CoreValue is proud to be listed as one of the Top Web and Software Development Companies of 2018 in the USA, according to TopDevelopers.co. The researched list includes 50 web and software development companies that provide exemplary software development proficiency. TopDevelopers.co noted the high level of expertise CoreValue handled projects for different business sectors with. […]