Skip to content

Latest commit

 

History

History
35 lines (18 loc) · 4.42 KB

W16_lab05.md

File metadata and controls

35 lines (18 loc) · 4.42 KB

A. The cs56-scrapers-ucsb-cirriculum project is rototype object for screen scraping the Cirriculum Search page. It gets the data based on the input in the format: DEPARTMENT, Quarter, Year, Level. (e.g. CMPSC, Spring, 2014, Undergraduate) and presents basic information of the class you searched up. It has no GUI and is completely terminal based.

B. As a student I can search up a class I'm planning to take, in order to find the times and current capacity of the class.

As a student I can search up a class from a previos quarter/year, in order to see how popular or full some classes I'm planning to take are.

As a student, I can search a class in order to see where the class is located.

As a professor, I can see how many students were enrolled in previous quarters of the class, in order to ask for a classroom with enough space for everyone.

As a professor, I can see how many sections were used in previos quarters, in order to prepare enough TA's for the course.

C. The software runs; however, it is solely terminal based.

D. As a student, I can add the courses I'm taking directly to my calendar app (Google, Sunrise, etc.) in order to save time from doing that myself.

As a student, I can search a course, in order to find the time and day of the final exam.

As a student, I can run the program with a user friendly UI, in order to have an easier time accessing the information I need.

As a professor, I can see projected enrollment based on older data, in order to have a decent grasp of how many people to expect.

E. Although detailed in how to run the program, the readme could have a small project description at the top in order to quickly see what the application does.

F. There is bare minimum number of comments in the build.xml; as such, there are descriptions needed for the targets and separate parts of the build file.

G. There are a decent number of issues, the biggest two being the try catch blocks and the GUI for the project to be worth 1000 points.

H. 1. One more issue that can be added is "Add Tests" as the testing suite is not very extensive, with classes such as UCSBSection not even having a single test to its name. Link: #17 2. Another issue is that there are plenty of methods whose code are merely stubs. These are not necessary, but add search criteria to get classes. #18

I. The code is organized into three main java classes: UCSBLecture, UCSBSection, and UCSBCirriculumSearch. It is fairly clear on how these three classes work together. All the files have sufficient comments in order to quickly grasp what the code does ie: "When searching for courses, the HTTP POST method must be used---this method helps to encode the HTML Form parameters properly (using URLEncoding)." However, there are still some "TODO:" comments, when they seem to have already been done. The code is easy to read as the writers used standard coding style along with coming up with good names/labels for their functions and variables. To get a programmer up to speed, I would simply tell him/her how the classes interact with each other and which functions each class serves. For example, the UCSBCirriculumSearch class scrapes through the provided URL in order to get the desired data we need to find out which courses there are with the provided search critera. Next, the UCSBLecture class takes in that data to create an object that represents a single course's lecture information while the UCSBSection class does the same thing, just it takes in the information for a classs section.

J. The testing is not extensive. For example, UCSBSectionTest is a completely new file with no tests written other than a comment "TODO:". In addition, UCSBCirriculumSearchTest has only a single assert call; thus, it only has one test going for it. On the other hand, UCSBLectureTest has a much more extensive testing suite compared to the others. However, it seems that the ToString function only has a single test case. One more thing of note, is that the tests that are there are cover JUNIT, but there are definitely many oppurtinities to expand the test coverage. To do so, we could initiate more variables and objects to run the tests. In addition, for SectionTest, we have to write all the tests as it has none. For this, we could test its setters and getters along with the functions toString and equals in the same vain as before.