All Questions
5 questions
-2
votes
1
answer
4k
views
Test Class for RestResource gives "Methods defined as TestMethod do not support Web service callouts" error [duplicate]
Looking for some help here. I'm trying to write a Test Class for a RestResource I defined but am receiving the above Test Class failure. I was under the impression that you didn't need to define a ...
0
votes
1
answer
48
views
Apex Unit Test for Rest Resource calls wrong class
I have 2 RestResource classes:
@RestResource(urlMapping='/Catcher/*')
global Without Sharing class vecCatcher {
@HttpGet
global static void httpGet() {
...
}
}
and
@RestResource(...
1
vote
1
answer
41
views
Test Class calling Rest Resource with List containing multiple variable types
I have a RestResource class that is called by our backend to perform a specific action. The problem is that when I attempt to test for this class, I run into a snag. The Class accepts a JSON file from ...
2
votes
1
answer
2k
views
Test Method for @HttpPost RestResource is not returning expected results
I have been looking all over the boards and found some useful posts regarding testing rest services, but even after spending the last 2 hours trying to implement many of those ideas, I still am stuck ...
2
votes
1
answer
15k
views
A testclass for @RestResource @HttpPost
I have a @HttpPost method in @RestResource class:
@RestResource(urlMapping='/Something/*')
global with sharing class HttpClass {
@HttpPost
global static String updateCustomObject() {
//Fetching ...