Salesforce Certified Platform Development Lifecycle and Deployment Architect (Plat-Arch-202) Exam - Topic 8 Question 8 Discussion
A developer on the Universal Containers team has written a test class to test a methodthat involves a web service callout. Within the test class, the developer is supposed to load testdata, create an instance of the Mock object, set the Test.setMock() to that Mock object, callstartTest(), execute the code that makes the callout, call stopTest(), and compare the result withexpectations. Unfortunately, theDeveloper forgot to use the Test.setMock() method step.What would happen when the developer runs this test class?
B) The test class fails and the developer will see a message stating: Methods defined as
TestMethod do not support Web service callouts.
A) The test class fails without error message since the test class will simply skip the web
service callout during the execution.
C) The test class would make the web service callout and may or may not fail depending on
the circumstances on the web service end
D) It is impossible to miss the Test.setMock() statement, the Developer Console will not let
the developer save it since the test methou callout
Miss
7 months agoKate
7 months agoJesusa
7 months agoBette
8 months agoIesha
8 months agoColette
8 months agoBrynn
8 months agoEladia
8 months agoGermaine
8 months agoClarinda
8 months agoLorean
8 months agoRachael
8 months agoBambi
8 months ago