It's UWAweek 26 (mid-year break)

help2005

This forum is provided to promote discussion amongst students enrolled in CITS2005 Object Oriented Programming.

Please consider offering answers and suggestions to help other students! And if you fix a problem by following a suggestion here, it would be great if other interested students could see a short "Great, fixed it!"  followup message.

How do I ask a good question?
Displaying the 3 articles in this topic
Showing 3 of 257 articles.
Currently 8 other people reading this forum.


 UWA week 20 (1st semester, week 11) ↓
SVG not supported

Login to reply

👍?
helpful
6:31pm Fri 17th May, ANONYMOUS

Hi! I'm not sure when I manually press the run button in vscode it says my code doesn't work for StudentListIterator and StudentStats but when I do PS C:\Code\Java\src> javac itertools/*.java studentapi/*.java studentstats/*.java test/*.java PS C:\Code\Java\src> java test.Test it gives me 11/11 is this an issue of concern or will it be okay since it passes when I manually do javac. I'm on windows if that information is needed. Thanks in advance


SVG not supported

Login to reply

👍?
helpful
8:21pm Sun 19th May, Edward B.

One of the steps I would try for this is: 1. Close all your VScode windows / tabs 2. Open "folder" and choose your src folder 3. Open the Test file and then try pressing the run button Sometimes VSCode has issues "finding" packaged files for some reason. Obviously check your code using the provided instructions prior to submission.


 UWA week 21 (1st semester, week 12) ↓
SVG not supported

Login to reply

👍?
helpful
11:00am Mon 20th May, Andrew G.

ANONYMOUS wrote:
> Hi! I'm not sure when I manually press the run button in vscode it says my code doesn't work for StudentListIterator and StudentStats but when I do > PS C:\Code\Java\src> javac itertools/*.java studentapi/*.java studentstats/*.java test/*.java > PS C:\Code\Java\src> java test.Test > > it gives me 11/11 > > is this an issue of concern or will it be okay since it passes when I manually do javac. I'm on windows if that information is needed. Thanks in advance
I do not use VS Code, and so cannot diagnose its behaviour when clicking the run button. Make sure you know what it is compiling and what it is running, as if it only compiles some of your source code files, this could lead to the tests not representing the results of your code. I also do not use and cannot diagnose PowerShell, but assuming you have not modified the tests, the commands you have given seem correct. The first would compile every java source file in the listed directories. This means it would not get things in subdirectories of `test/`, such as `test/itertools/ItertoolsTest.java`. But if you have not modified the tests, then your command should recompile everything that may have changed, as well as making sure the `test.Test` is compiled. So I would guess that your code should be fine and would pass all tests if submitted as-is. I do not know why VS Code might not be compiling things properly. If you choose to use VS Code then any issues it produces are your own to resolve. Best practice to be sure is to make sure you delete all the .class files that have been generated and recompile and run the tests from scratch, as that is what the automarker will be doing (since you are instructed to submit only .java files, and so .class files will be ignored).

The University of Western Australia

Computer Science and Software Engineering

CRICOS Code: 00126G
Written by [email protected]
Powered by history
Feedback always welcome - it makes our software better!
Last modified  5:07AM Sep 06 2023
Privacy policy