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
anirbasdevanirbasdev 

test controller extension

i need some assistance writing a test class for this extension controller :
public with sharing class ControllerOppRel { public Product2 opptyList; public ControllerOppRel (ApexPages.StandardController stdController) { opptyList = (Product2)stdController.getRecord(); } public List<OpportunityLineItem> getOpprel(){ return [SELECT Id, Product2Id, OpportunityId,Opportunity.Name,Opportunity.StageName,Opportunity.Account.Name, TotalPrice FROM OpportunityLineItem WHERE Product2Id=:ApexPages.currentPage().getParameters().get('id')]; } }