Skip to content

Implement 'withField.setTo' #97

@bobalicious

Description

@bobalicious

withFieldsSetTo is a very useful method for checking that an SObject has certain fields set to certain values, but it can be a little long-winded for checking a single value.

E.g.

.when( 'exampleMethod' )
.withParameterNamed( 'sObjectParameter' ).withFieldsSetTo( new Map<String,Object>{ 'IsPersonAccount' => true } )

It would be preferable to have a shorter-hand version of it that allows a single field value to be checked:

E.g.

.when( 'exampleMethod' )
.withParameterNamed( 'sObjectParameter' ).withField( 'IsPersonAccount' ).setTo( true )

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions