• Ankit Randhawa
  • NEWBIE
  • 0 Points
  • Member since 2020

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 1
    Replies
I have a seemingly simple Test I wrote but when run it receives the error: Methods defined as TestMethod do not support getContent call. I do not have a .getContent call in my Test. I have narrowed down the error to most likely be the line "conid.add(con.Id);". I'm think the .add() when called acts like a .getContent()? Any thoughts on a way around the call?
Thank you,
Ryan
@isTest
public class Test_EchoSign2 {
    static testmethod void testechosign(){
    	Account ac = new Account(RecordTypeId = [SELECT Id, SobjectType, Name FROM Recordtype WHERE Name = 'Prospect/Client' AND SobjectType = 'Account' LIMIT 1].Id);
    	ac.Name = 'TestAcnt';
    	ac.Type = 'Prospect';
    	insert ac;
    
		Contact con = new Contact(RecordTypeId = [SELECT Id,SObjectType,Name FROM RecordType WHERE Name = 'Prospect/Client' AND SobjectType = 'Contact' LIMIT 1].Id);
		con.LastName = 'testLastName';
    	con.AccountId = ac.Id;
        con.Email = 'ryan.greene@outlook.com';
	    con.LeadSource = 'Unknown';
        insert con;
 
        List<Id> conid = new List<Id>();
        conid.add(con.Id);
		EchoSign.SendPdf(conid);
    }
}