Lesson 7 Constructors and Inheritances 7c The Donut Class

The teacher example gives me the following error:

/DonutTest.java:26: error: cannot find symbol

donutConstructors = ConstructorsHelper.getClassConstructorsList(donutClass, "Donut");

                    ^

symbol: variable ConstructorsHelper

location: class DonutTest

/DonutTest.java:52: error: cannot find symbol

ArrayList<String> actualParameters = ConstructorsHelper.getParameters(actualConstructor);

                                     ^

symbol: variable ConstructorsHelper

location: class DonutTest

/FoodTruckRunner.java:16: error: cannot find symbol

ConstructorsHelper.printConstructors(plainDonut);

^

symbol: variable ConstructorsHelper

location: class FoodTruckRunner

/FoodTruckRunner.java:20: error: cannot find symbol

ConstructorsHelper.printConstructors(chocolateDonut);

^

symbol: variable ConstructorsHelper

location: class FoodTruckRunner

[EXCEPTION] We couldn’t compile your program. Look for bugs in your program and try again.

[JAVALAB] Program completed.

What did I do wrong?

Hi @eabruzzo ! Thank you for bringing your question to the forum. I know issues like these can be aggravating. Without seeing your code it’s hard to diagnose the problem. Would you mind clicking the “Share” button –> “Copy Link to Project” and paste it here in your reply?

In the meantime, I would check that your Classes and files are named as specified in the project writeup.

Hopefully we can get to the bottom of this for you!

Best,

-Sam

This is not my code but the Teacher’s example. I hope that helps.

Ethan

Hi Ethan (@eabruzzo ),

This is a very curious issue. I got the same errors you did when I ran the tests when I opened the exemplar code. However, I copied and pasted the code from the exemplar into my level and passed all the tests. So I this leads me to believe the code in the exemplar is correct but the tester class isn’t working in the exemplar window?? I’ll send a report to support@code.org and see if they can tell me any more about what is happening. This is an email address that is available to anyone if you see any strange behavior like this.

As I said before, I’m glad you brought this to the forum in case anyone else comes across this issue.

Best,

-Sam

Hi @eabruzzo ,

This is the reply I got from code.org after I emailed support:

**
Andrew** (Code.org Support)

Nov 13, 2025, 3:10 PM PST

Hello Samuel,

Thank you for contacting Code.org!
*
Please be aware that with exemplars on Java Lab like this that rely on support files (like ConstructorsHelper / AttributesHelper / FileReader, etc), you will need to copy-paste the class files over into the code editor to run. *
*
This is unfortunately a limitation of Java Lab.*
*
We apologize for the inconvenience. *
*
If you have any additional questions, please let us know.*

So it looks like the exemplar code needs to be copy and pasted into a regular level.

Best,

-Sam

Thank you for the help.

Sincerely,
Ethan Abruzzo