[SalesForce] Ensure sharing rules from the calling class are enforced for the the ‘UtilityClass’ Apex class

Getting below error while attempting Winter 19- Platform Developer Maintenance exam Hands on Challenge.

Ensure sharing rules from the calling class are enforced for the the 'UtilityClass' Apex class.

Class code is same as given in this trailhead module :
Trailhead Module

Modified below classes as asked in the above mentioned Hands on challenge
UtilityClass:

public Inherited Sharing class UtilityClass {
   ...
}

TowerMapControllerClass : (Tried With Sharing/Inherited Sharing/Nothing for this class)

public With Sharing class TowerMapControllerClass {..}

Best Answer

I replaced 'Inherited Sharing' with 'inherited sharing' then trail-head passed the challenge.

Though apex is case insensitive, syntactically my code is correct and class is saved. Trail-head validation check for case sensitive match.

Its an issue with trail-head challenge validation.

Related Topic