CST 338 Week 3
Shapes Lab Code Review
I evaluated Anthony Torres and Zeyad Abdelkader from my group. Their code was clean and concise throughout. Both of their variable names and formatting were excellent and easy to read. For Anthony, every method had comments that explained what they do and what they return. Zeyad's was missing comments much like mine, but everything else looked good. Both had very efficient logic, no unused warnings, and their unit tests all passed.
Feedback I got:
Both told me that my code was lacking comments and some parts were unfinished. Variable names and formatting that did exist were good, but could be cleaned up a little.
I absolutely need to improve at setting comments as I work. I tend to leave them until after and end up forgetting about them. My unit tests were also a bit chaotic and not as thorough as they could be.
Testing the ShapeReader's shapesFromFile() was the hardest at the time. I didn't have a full understanding of how to create a test file for this unit test and how to have scanner read from it.
- Do the existing unit tests cover the full range of the sub classes?
No, I had missing unit tests such as ShapeReader's. Aside from that, I also messed up with the repository and one of the tests I wrote in the previous week was lost.
- How would you change the unit tests?
- Keep in mind I do not want them to change but this doesn't mean I
think they are perfect. Reading through the tests is a good way to
learn what the code should do thinking about how to test the codeis a
good way to learn how to make tests.
I think the unit tests I had could've been more extensive. Some of them ended up being a single assertEquals or assertNotEquals with a local variable.
- Keep in mind I do not want them to change but this doesn't mean I
think they are perfect. Reading through the tests is a good way to
learn what the code should do thinking about how to test the codeis a
good way to learn how to make tests.
The scanner, file, and try/catch were all very difficult for me and not included when I turned in the file originally. I think I could do them now.
Several parts as I was still getting used to Java and relearning many programming concepts.
Once I had an understanding of how Dr C. wanted us to write unit tests, the getters and setters became particularly easy.
Nothing specific. Just being able to look at this code and mostly understand it now feels like a big victory.
Comments
Post a Comment