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
roshrosh 

test class? please help for this is urgent


public class VConnect_EInvoiceAuraHelper {
    @AuraEnabled
    public static void getInvoice(Id recordId) {
        // do some preprocessing.
        // execute the batch here
        Set<Id> poids = new Set<Id>();
        poids.add(recordId);
        System.debug('Called');
        Id jobId = Database.executeBatch(new BatchClassEInvoice(poids),200); // optional batch size can be provides as well.
    }
}
Salesforce TechieSalesforce Techie
in test class just call the method getInvoice and pass the record id you created 
roshrosh
Haven't created record till