nerdexam
Salesforce

CRT-450 · Question #17

A developer wrote Apex code that calls out to an external system. How should a developer write the test to provide test coverage?

The correct answer is B. Write a class that implements the HTTPCalloutMock interface. See the full explanation below for the reasoning.

Question

A developer wrote Apex code that calls out to an external system. How should a developer write the test to provide test coverage?

Options

  • AWrite a class that extends HTTPCalloutMock.
  • BWrite a class that implements the HTTPCalloutMock interface.
  • CWrite a class that implements the WebserviceMock interface.
  • DWrite a class that extends WebserviceMock

How the community answered

(49 responses)
  • A
    10% (5)
  • B
    80% (39)
  • C
    4% (2)
  • D
    6% (3)

Community Discussion

No community discussion yet for this question.

Full CRT-450 Practice