You need to sign in to do that
Don't have an account?
L3n
No Apex class named 'StringArrayTest' was found
Hi, Can you please help.
I'm working on this Trailhead challenge:
Create an Apex class that returns an array (or list) of formatted strings ('Test 0', 'Test 1', ...). The length of the array is determined by an integer parameter.
This following is my code sample:
The test command is:
and the result I see is:
I don't understand why the trailhead is saying:
Challenge not yet complete... here's what's wrong:
No Apex class named 'StringArrayTest' was found
I even tried logging out and back in again.
I'm working on this Trailhead challenge:
Create an Apex class that returns an array (or list) of formatted strings ('Test 0', 'Test 1', ...). The length of the array is determined by an integer parameter.
This following is my code sample:
public class StringArrayTest { // Public method public static List<String> generateStringArray(Integer numTests) { // Create a list List<String> Tests = new List<String>(); for (Integer i=0; i<numTests; i++){ Tests.add('Test '+ i); system.debug(Tests[i]); } return Tests; } }
The test command is:
StringArrayTest.generateStringArray(7);
and the result I see is:
I don't understand why the trailhead is saying:
Challenge not yet complete... here's what's wrong:
No Apex class named 'StringArrayTest' was found
I even tried logging out and back in again.
Please let us know if this will help you