B25.Test_FormHelper.TestFormContext

Overview

To test your custom form API implementation you need to be able to specify the state of the form when the event handlers are fired. This class contains this state.

Example

1 2 3 4 5 6 7 8 B25.Test_FormHelper.TestFormContext formContext = new B25.Test_FormHelper.TestFormContext(); formContext.reservation = new B25__Reservation__c( B25__StartLocal__c = Datetime.now(), B25__EndLocal__c = Datetime.now().addHours(1) ); formContext.relatedSObjects.put('B25__ReservationContact__c', new List<SObject>{ new B25__ReservationContact__c() });

Properties

Name

Type

Description

reservation

B25__Reservation__c

The reservation on the form during the firing of the event.

relatedSObjects

Map<String, List<SObject>>

The related lists on the form during the firing of the events.

On this page