You need to sign in to do that
Don't have an account?
Jim Shorkey 6
Apex Testing
I am trying to learn Apex coding and I am unable to figure out how to write a test class for the code below:
public class FilterTasksCall {
public Task[] tasks {get; private set;}
public FilterTasksCall() {
Id id = (Id) ApexPages.currentPage().getParameters().get('id');
tasks = [Select
Who.Id,
Who.Name,
Id,
Subject,
What.Name,
ActivityDate,
Owner.Name,
Status,
LastModifiedDate
From Task
Where Subject Like '%Call%' and Who.Id=:ApexPages.currentPage().getParameters().get('id')];
}
}
Thank you and your help is very much appreciated,
Jim
public class FilterTasksCall {
public Task[] tasks {get; private set;}
public FilterTasksCall() {
Id id = (Id) ApexPages.currentPage().getParameters().get('id');
tasks = [Select
Who.Id,
Who.Name,
Id,
Subject,
What.Name,
ActivityDate,
Owner.Name,
Status,
LastModifiedDate
From Task
Where Subject Like '%Call%' and Who.Id=:ApexPages.currentPage().getParameters().get('id')];
}
}
Thank you and your help is very much appreciated,
Jim
Try this code cover this class-
Thanks
Rupal kumar
http://mirketa.com
All Answers
Try this code cover this class-
Thanks
Rupal kumar
http://mirketa.com
Thank you so much. This worked perfectly.
Jim