All Questions
9 questions
0
votes
1
answer
68
views
Loop Element not reaching If Condition
Really two different things here. What this is doing is comparing the Email addresses of an external platform (Zuora Billing platform) to email addresses and accounts that already exist within SFDC.
...
-2
votes
2
answers
57
views
How do I test the FOR loop data for this code?
I have written a test class for a class and its coverage is above 75% but I want to increase it and found that a particular for loop is not being covered(written Between ** below). Please help me with ...
1
vote
2
answers
170
views
How can I create 1500 contacts for my units tests without hitting CPU limit?
I am creating a script that gets run every quarter that checks for any paid status in campaignMember objects that has contactId attached, and update the status to unpaid and create a campaignMember ...
2
votes
1
answer
67
views
Counter only adds first opportunity id
I have a testclass in which I create serveral opportunities with several values when I system debug these the values are as espected. I use a counter to add the ids from the several opportunities to ...
1
vote
1
answer
222
views
The Looping through a Static Resource List is Not Obeying Conditions
In a test, I load a static resource containing 17 records (rows) for my custom Case Assignment object.
A checkbox on this object is named Incorrect__c.
Three of the records have Incorrect__c of ...
1
vote
1
answer
3k
views
Test Class: Unable to Cover For Loop
I'm stumped because I cannot cover a simple for loop in my test class on the Opportunity object. Lines 15 through 28 are not being covered by my test class. I've inserted the Contracts, and yet the ...
0
votes
1
answer
49
views
void loop runs no effect
I am attempting to write a simple test for a for loop that cleans the websites fields of unwanted elements such as 'http', 'www' etc. The script works for me but the test class that I wrote gets me 0% ...
0
votes
2
answers
117
views
For loop testing in Salesforce
I am attempting to write a simple test for a for loop that cleans the websites fields of unwanted elements such as 'http', 'www' etc. The script works for me but the test class that I wrote gets me 0% ...
1
vote
1
answer
179
views
Many unnested loops cause 'Apex CPU time limit exceeded'
I'm not sure what's happening, but all what I'm trying to do is to write a simple test class which inserting a lot of records. However, my records are related in different relations.
My test class is:...