comfort
    • Create new note
    • Create a note from template
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Write
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights New
    • Engagement control
    • Make a copy
    • Transfer ownership
    • Delete this note
    • Save as template
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Note Insights Versions and GitHub Sync Sharing URL Create Help
Create Create new note Create a note from template
Menu
Options
Engagement control Make a copy Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       Owned this note    Owned this note      
    Published Linked with GitHub
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    # **MyscannarApp** # ## **CA326 Testing Documentation** ## Comfort Dopamu & Mahjabeen Soomro ## Table of contents ## We need to have all these implemented. Only part 2 is done to satisfactory * [1.Interface Testing](#1-interface-testing) * [2.Unit Testing](#2-Unit-Testing) * [3.Android Studio logs](#3-android-studio-logs) * [4. Website Testing](#4-website-testing) * [5.Dummy Testing](#5-dummy-testing) * [6.Heuristic Analysis](#6-heuristic-analysis) ## 1.Interface Testing We tested MyScanner app on HTC dual sim and TECHNO mobile phone; here are the screenshots from both phones. ![](https://i.imgur.com/Wr2a8be.jpg) ![](https://i.imgur.com/gKGD6wY.jpg) ![](https://i.imgur.com/9Ng9ine.jpg) ![](https://i.imgur.com/JlJmi07.jpg) ## 2.Unit Testing We decided to do some unit testing to test some of our methods that were used often and contained any user input. While users use this so often, it is important to perform tests to decrease risk of something going wrong. We unit tested the following: ### Scan code Testing If the qr code is empty, this might cause the app to crash. The test did the following: * Allows users to scan both strings and digits. * Makes sure to check for empty qr codes to prevent the app from stopping. * Makes sure the qr code string length is not greater than 15. ![](https://i.imgur.com/3wW3vwv.png) ### View Attendance Testing Arraylist and shared preference saving We created two function test on the methods that were used in the view attendance activty. Adding items to arraylist and saving them in shared preference usign google gson as well. The test did the following : * Prevented the arraylist from adding empty strings. * Removes whitespace and returns the strings after converting to lowercase. * Shared preference allows arraylist to be stored as long as it is not empty. * shared preference saves and retrives arraylist. ![](https://i.imgur.com/uZGvIT5.png) ### Register Testing We used both android sqlite and flask mySql for the user registeration and login authentication. We however, made unit test to test the email address the users register with. They contain the following functionalities: * The passord must be in the correct form using "@". * The password must contain at least 6 characters. ![](https://i.imgur.com/kbwdSzC.png) ### Password and module checking We created functions to test the module code and the password. These test cases limit the number of errors the users can make while creating an account such as: * Prevent users from submiting empty module code * Whitespaces must be removed. * return the module codes in lowercase ![](https://i.imgur.com/GUN5ytE.png) ## 3.Android Studio logs Inorder to continuously track our progress, we used android studio log cat. This helped to display any error we encounter such as programming error, we were able to debug our android app easily. We also used log cat to display json data sent from our server to android studio and data sent from android app to the server. It is impossible to track our progress as it needs to be tested on an android app, however the logcat provided by android studio tremendously helped us to keep track of all our errors. Whenever we added to our dependencies in the build gradle, we were notified to sync our project immediately. Logcat made debugging easier. ![](https://i.imgur.com/JpTTkh7.png) This image shows how 'Log.d' alowed use to view the qr code string that we scanned. Log cat also allows us to view our connection to the server, if the server page is unresponsive we are notified. Below is an example of a server error when we attempted to login ![](https://i.imgur.com/xAlCP2a.png) ## 4. Website Testing It is complicated to test the website for any errors and what must have caused the error. The common website errors are 400,404 and 500; while we get the errors it is hard to tell what leads to this error. We decided to use our terminal to get the passed data from android studio to the app. We were then able to see that information was being sent to the server that could cause the website to crash. When we send a post request from the android app to the server we were able to view the information by printing the post parameter sent. Here is an example of a users information being sent to the server. ![](https://i.imgur.com/S7gWhJ2.png) A user attempted to login without inputing thier username and password, thus this could have caused an error in the log cat but we were able to view the real reason behind the error. The second 'LOG CALLED' shows us what the user entered during their login. ## 5.Dummy Testing We performed dummy testing in replace to actual users testing this app, this allowed us to see how the website would look if our app were to be used. ![](https://i.imgur.com/TT9z7Mj.png) The above image showed us the students who have scanned the provided qr code, the qr code that was scanned and the Date with time that this occured. The below image shows how many student are registerd with their username, email, ID and module. ![](https://i.imgur.com/mEyWesN.png) ## 6. Heuristic Analysis Our primary goal is to make an attendance tracking device to be used in schools by students. In order to mae use of this app, it must be accessible to all. In order to make this app accessible and easy to use, we ensured the following: * Used same theme for every activty * Made text big enough to read * Made buttons big and obvious * Place scan button in the middle * Used the right layout(Home activity should open after login page) * Make use of 'Toast' to display error message and flash quick message We also made the website simple to use and navigate. It primary goal is to view the students who scanned the qr code as it indicates that they attended lecture. We ensured the following * The lecture can use the search button to filter students of a specific class. * The pages have same stylings * Used same colour for all pages * lecture must be logged in to see students attendance

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password

    or

    By clicking below, you agree to our terms of service.

    Sign in via Facebook Sign in via Twitter Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully