New answers tagged

0

You cannot make a real outbound call of any kind in a unit test context. Typically, unit tests should not be dependent on the actual org in which they are executing. I would strongly recommend using a dummy URL in this class, and writing your assertions to validate the behavior of the class using that dummy URL. Note also that your code can always source ...


3

I have done this before, and not sure you actually need to store the list anywhere - you could just add the list of objects to the batch when you create it as a variable. Any variable you set when you invoke the batch are always available during the lifetime of the batch (though you need stateful if you want to track on-going counts) So build the list, ...


Top 50 recent answers are included