You need to sign in to do that
Don't have an account?
h20rider
Access to object in a test class
I have a few test classes where i I running under a different user
When I can quering objects I am getting 0 rows. For example the custom object: Pipeline_Stage__c
where I looked at sharing I see this.
Pipeline Stage
Public Read Only |
Any Ideas why I am not able to see all the records
Hi,
Please use the "IsTest(SeeAllData=true) Annotation" annotation in test class to fetch the record.
Please have a look on this help document.
http://www.salesforce.com/us/developer/docs/apexcode/Content/apex_classes_annotation_isTest.htm
All Answers
Hi,
Please use the "IsTest(SeeAllData=true) Annotation" annotation in test class to fetch the record.
Please have a look on this help document.
http://www.salesforce.com/us/developer/docs/apexcode/Content/apex_classes_annotation_isTest.htm
thanks. That worked. Ideally I want to have it be able query the data under that user. But at this time, I just want code coverage
thanks again