function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Jeff Bryant 16Jeff Bryant 16 

Error : Method does not exist or incorrect signature

I'm currently writing a test class and keep getting "Method does not exist or incorrect signature errors... I'm not certain or confident that I am writing the test class properly...

public class SetEMT {
    ApexPages.StandardController stdCtrl;
    public SetEMT(ApexPages.StandardController controller) {
    List<EmailTemplate> mmts;
    public String mmtid {get; set;}
    public String mmtname {get; set;}
    public String folder {get; set;}
    public List<EmailTemplate> getTemplates() {

        if(mmts == null) mmts = [select name, description from EmailTemplate order by Name];              
        return mmts;
    public void changeTemplates() {
      if(folder != null && !folder.equals('')) mmts = [select name, description from EmailTemplate where FolderId = :folder order by Name];
      else mmts = [select name, description from EmailTemplate order by Name];
    public List<SelectOption> getFolders() {
        List<Folder> folders = [select name, Id from Folder where Type = 'Email' order by name];
        List<SelectOption> options = new List<SelectOption>();
        options.add(new SelectOption('',''));
        for (Folder f : folders) {
            options.add(new SelectOption(f.Id,f.Name));
        return options;
    public void setTemplate() {
        EAST_Mailing__c mailing = (EAST_Mailing__c)stdCtrl.getRecord();
        mailing.PreApprovedEmailTemplateName__c = mmtname;
        mailing.PreApprovedEmailTemplateLink__c = URL.getSalesforceBaseUrl().toExternalForm() + '/' + mmtid;
        update mailing;

@ istest (SeeAllData=true)
public class SetEMTTest
    private static testmethod void validate(){
        List<EmailTemplate> eList = new List<EmailTemplate>();
        EmailTemplate e = new EmailTemplate (Name = 'Test Template', TemplateType= 'Text');   
        ApexPages.StandardSetController setCtr = new ApexPages.StandardSetController(eList);
        SetEMT.setSelected(new EmailTemplate[]{e});
        MassUpdateSimpleController controller = new MassUpdateSimpleController(SetEMT);
You class name where this method exists in "SetEMT", check first line of your posted code "public class SetEMT {"
You initiated MassUpdateSimpleController, below code of your test class

MassUpdateSimpleController controller = new MassUpdateSimpleController(SetEMT);
// and calling method getTemplates() which is not present in MassUpdateSimpleController

instead use setCtl to fix this error

Leanbridge TechnologiesLeanbridge Technologies
Make the changeObject method a static method
public static void changeOject(list<le_object__c> newList, list<le_object__c> oldList){ }
And you do not need to instantiate the class in the trigger, as the method is now static you can directly call the method something like this:
TestingTrigger.changeObject(, trigger.old);