Primary School Application - Technical Report
- April Hussey

- Apr 8, 2023
- 5 min read
Updated: Feb 2, 2024
Account Usernames and Passwords
User ID | Password | First Name | Last Name |
pBarker | Pepsi4EVER | Philippa | Barker |
yHolmes | 1mBatb0y | Yasin | Holmes |
eDavison | T1nk3rb311 | Ella | Davison |
rMorton | R0saM1tch3ll | Rosa | Morton |
gReed | Jasper3 | Gerald | Reed |
cHunt | i<3Rosa | Ciaran | Hunt |
pMitchel | Barbie007 | Polly | Mitchel |
rDuncan | h3ll0Rocco | Rocco | Duncan |
gSingh | boysF3RDA | Glenn | Singh |
cCastro | cats4LIFE | Caitlin | Castro |
Account Used for Testing
User ID | Password | Test | User |
Features Implemented
Feature | Implemented (Partial / Full) | Comments |
Fixed Username and Password Login | ||
User can login using 10 different fixed username and password logins | Full | |
User information and details displayed at the top of application | Full | |
File Storage | ||
User can create a file – the name of the file is defaulted to the users’ name and the current date | Full | |
User can update the name of a file | Full | |
User can delete a file | Full | This is done by long clicking the file. |
User can update the contents of a file | Full | |
User can view all the files that have been created displayed in a recycler view | Full | |
Multiple Choice Quiz | ||
User can select the correct answer by selecting the right radio button | Full | User can choose to not select one of the radio buttons and receive no mark for that question |
Quiz will display the mark (score) for the user at the end of the quiz | Full | |
User can choose to save their score to a file – the file contains the name of the user and the score from the quiz | Full | |
Additional Features | ||
Graphical User Interface | ||
Inherent to the rest of the application | Full | |
Images in Quiz Activity | ||
Quiz activity has images to assist with questions | Full | |
Activity Lifecycle Callbacks | ||
Applications uses activity lifecycle callback onCreate() | Full | |
Dice Roller | ||
User can roll a dice and get a random number | Full |
Design Implementation
Going into this project, I decided to first focus on getting my application in a functional state.
I started by creating the 10 fixed username and password logins. I did this by creating a custom ‘User’ class that would hold all the information I felt necessary for a fixed user login – user ID, password, first name, and last name. So that these new fixed logins could be utilised, I created a ‘LoginSystem’ class handles, authentication, modifying users, deleting users, and tracking the user currently logged in.
To create the login screen, I used text views, edit texts, and a button in the ‘MainActivity’. To keep the layout simple, I used a linear layout with a vertical orientation – I ended up using this general layout for most of my activities.
When a login is successful (the user is authenticated) the user is taken to the ‘DashboardActivity’. Like the login screen, I created this activity as a linear layout with a vertical orientation and used a mixture of text views, edit texts, and, what ended up being image buttons. Each image button – ‘My Files’, ‘Quiz’, and ‘Dice Roller’ - takes the user to another activity.
The ‘My Files’ image button takes the user to the ‘FileStorageActivity’. This activity is built up out of a linear layout with a vertical orientation, text views, a button, and a recycler view in a nested scroll view. Using a nested scroll view here means that no matter how matter files the user has, the user will be able to scroll and access all of them.
The purpose of the ‘FileStorageActivity’ is to allow the user to create, edit, and delete files. To create a new file the user must click the ‘New File’ button; this will create a file where the title will be the user’s name and the current date – the contents will be empty. At this point the user can click on the file, which will open a new activity – ‘FileActivity’.
‘FileActivity’ is built up out of a linear layout with a vertical orientation, a text view, a button, an edit text, and a second edit text inside of a nested scroll view. By having the second edit text (the contents of the file) inside a nested scroll view the user will not have to worry about writing too much as they will be able to scroll to see the entirety of the file’s contents. The purpose of ‘FileActivity’ is to handle the saving of existing files that have been edited.
In ‘FileActivity’, I implemented a boolean to check if the action of saving the file had taken place. When the user presses the back button if this boolean is false, a save prompt will pop up giving the user the option to save any unsaved changes in the file. If the boolean is true (the user has already saved the file), then the save prompt will not pop up when the user pressed the back button. I decided to implement this so that the user would not have to deal with any redundant popups.
The ‘Quiz’ image button in the ‘DashboardActivity’ takes the user to the ‘QuizActivity’. This activity is built up out of a linear layout with a vertical orientation, text views, an image view, a radio group with four radio buttons, and a button.
To better handle the questions for the ‘QuizActivity’ I created a custom ‘Question’ class that holds all the information needed for a question. So that I could have questions with and without images I created two defaults for the class. One holds a string containing the question, an array of the answer options, and an int that represents the correct answer in the ‘answerOptions’ array. The other, holds the same as the previous but also holds a int that represents the image from the res/drawable folder.
Inside of the ‘Question’ class, in addition to the getter functions, I have a function that returns a boolean that checks if a question has an image. By using that function in ‘QuizActivity’ I can have questions with and without images in the same quiz where each element of a ‘Question’ can use the same views as a different ‘Question’.
Once the user submits their answer to the final question in the ‘QuizActivity’ they are taken to the ‘QuizMarkActivity’; it is built up out of linear layout with a vertical orientation, text views, and buttons.
The purpose of the ‘QuizMarkActivity’ is to show the user the score they got on the quiz and give them the option to save it to a file. Clicking the ‘Save Score’ button will create a new file with the user’s name and quiz score in the contents, the file title will be the name of the quiz and the current date. The file gets saved using the ‘saveFile’ function from the ‘FileActivity’. So that the user will not be able to infinitely save their score and create a new file each time, I implemented a boolean to check if the action of saving a file had taken place. This is also used for when the user presses the back button, as I implemented a save prompt popup that checks if the user wants to save their quiz score. By having the boolean check I can ensure that, that prompt only popups when the user hasn’t already saved their score.
The ‘Dice Roller’ image button in the ‘DashboardActivity’ takes the user to the ‘DiceRollerActivity’. This activity is built up out of a linear layout with a vertical orientation, text views, an image view, and a button.
The ‘DiceRollerActivity’ is relativity simple, it is a random number generator that generates a number between one and six. Depending on which number is generated an image of a die with the same number is shown. To make this change of image more seamless I incorporated some animations to make the image rotate and scale down before the number changes, then after the image has changed to match the randomly generated number, the image would rotate and scale up to its original size.
After getting the functionality of my application to a mostly finished state, I started working on the graphical elements for my application. I started with the ‘DashboardActivity’ as it was the activity, I had the clearest idea for. I decided to create a background that looked like a corkboard and have each button be a sticky note. To make this change, I had to make the buttons, image buttons instead. This set the president for what the rest of my application would look like.
For the ‘DiceRollerActivity’, I kept the same frame from the corkboard background I created, but instead of the cork, I made it green so that it would be reminiscent of a pool or snooker table. While pool or snooker are not directly related to dice, I felt that the combination of the green and die worked well. I also made the 6 die images needed for the dice roller to be a dice roller opposed to just a random number generator.
For the ‘MainActivtiy’ (login screen), ‘FileStorageActivity’, ‘FileActivity’, ‘QuizActivity’, and ‘QuizMarkActivity’, I once again used the same frame as before and chose a white background, to make the background look like a whiteboard.
For the UI, my goal was to create an atmosphere that was akin to a school environment, and I believe succeeded in doing so.
Class Diagram
Sequence Diagram of Login File Storage Systems
Screenshots of System showing Key Features
Testing
Black Box Testing (user)
Description | Expected Outcome | Actual Outcome | Result |
Login with correct login information | ‘Dashboard’ opens | ‘Dashboard’ opens | PASS |
Login with incorrect login information | Text popup saying that UserID or Password is incorrect | Text popup saying that UserID or Password is incorrect | PASS |
Clicking ‘My Files’ on ‘Dashboard’ | ‘My Files’ opens | ‘My Files’ opens | PASS |
Clicking ‘New File’ button in ‘My Files’ | ‘New File’ is created | Nothing happened | FAIL |
Clicking ‘New File’ button in ‘My Files’ | ‘New File’ is created | ‘New File’ is created | PASS |
Clicking ‘File’ in ‘My Files’ | ‘File’ opens | Nothing happened | FAIL |
Clicking ‘File’ in ‘My Files’ | ‘File’ opens | ‘File’ opens, but it isn’t the same as in ‘My Files’ | / |
Clicking ‘File’ in ‘My Files’ | ‘File’ opens | ‘File’ opens as expected | PASS |
Long click ‘File’ in ‘My Files’ | Popup to delete ‘File’ appears | Popup to delete ‘File’ appears | PASS |
Clicking ‘Yes’ on delete ‘File’ popup | ‘File’ is deleted | ‘File’ is not deleted | FAIL |
Clicking ‘Yes’ on delete ‘File’ popup | ‘File’ is deleted | ‘File’ is deleted | PASS |
Clicking ‘Quiz’ on ‘Dashboard’ | ‘Quiz’ opens | ‘Quiz’ opens | PASS |
Clicking ‘Dice Roller’ on ‘Dashboard’ | ‘Dice Roller’ opens | ‘Dice Roller’ opens | PASS |
White Box Testing (programmer)
Description | Expected Outcome | Actual Outcome | Result |
Clicking ‘Roll Dice’ button in Dice Roller Activity | The die image will scale down while rotating 360 degrees for 1 second, before scaling up while rotation 360 degrees for 1 second with a randomly generated number | The die image skipped to being large and scaled up before scaling down, larger than expected (while rotating). Skipped to being normal size after | FAIL |
Clicking ‘Roll Dice’ button in Dice Roller Activity | The die image will scale down while rotating 360 degrees for 1 second, before scaling up while rotation 360 degrees for 1 second with a randomly generated number | The die image disappeared for roughly a second before appearing with a randomly generated number | FAIL |
Clicking ‘Roll Dice’ button in Dice Roller Activity | The die image will scale down while rotating 360 degrees for 1 second, before scaling up while rotation 360 degrees for 1 second with a randomly generated number | The die image scaled down while rotating 360 degrees for 1 second, before scaling up while rotating 360 degrees for 1 second with a randomly generated number | PASS |
Deleting files in File Storage Activity | Files will be deleted; recycler view will update accordingly | Deleting multiple files in a row in the File Storage Activity too quickly can sometimes lead to the wrong file being removed from the recycler view. This can lead to the app crashing if the user tries to delete the already deleted file that is still in the recycler view | FAIL |
Deleting files in File Storage Activity | Files will be deleted; recycler view will update accordingly | Files are deleted, recycler view updates accordingly | PASS |
Saving file in File Activity with ‘/’ in the fileTitle | File will save with /’ in the fileTitle | fileTitle didn’t change | FAIL |
Saving file in File Activity with ‘/’ in the fileTitle | File will save with a ‘-‘ instead of a ‘/’ in fileTitle | File saved with a ‘-‘ instead of a ‘/’ in fileTitle | PASS |
Bug List
None known









Comments