Skip to content
Snippets Groups Projects
Commit ed2ddd32 authored by Usman Irfan's avatar Usman Irfan
Browse files

Updated documents

parent 0758ab20
No related branches found
No related tags found
No related merge requests found
No preview for this file type
......@@ -33,6 +33,7 @@ Sept 28, 2018 & Andy & Proof of concept, Git workflow, Final editing and formatt
Sept 28, 2018 & Usman & Updated proof of concept\\
\textcolor{blue}{Oct 12, 2018} & Andy & Made changes according to feedback on development plan and added section on POC demo\\
\textcolor{red}{Dec 2, 2018} & Vaibhav Chadha & Revision one changes to improve the documents quality.\\
\textcolor{red}{Dec 2, 2018} & Usman Irfan & Revision one changes to improve the documents quality.\\
\bottomrule
\end{tabularx}
\end{table}
......@@ -110,8 +111,8 @@ The following procedures will be followed:
\end{itemize}
\section{Proof of Concept Demonstration Plan}
The original project is built using \textcolor{red}{JavaScript}, HTML and CSS in contrast to our development plan using python and the Pygame library. Since we are using an OOP language, we will be able to create classes for different components of the snake game such as the snake unit block, snake body, and snake bate. The hardest part of the implementation will be the movement of the snake according to the user's keyboard inputs, and second to that would be the process of expanding the snake once a food item is captured. Besides that, the interface may be difficult to implement in python but could be simple with the use of a python framework such as PyQT5.\\
Once our game application has been developed the next part would be to test the project and for that we will be using Pytest, since our backend language is python this will help us test all possible functions and aspects. The functions that will be difficult to test would be to see if the snake eats the food, does the food appear at random locations after eaten by the snake and if the snake tries to leave the borders, will the game end. Portability will have to be taken into consideration since the application is being built for windows. However, it can be compiled and run on any system as long as the necessary files and libraries are download.
The original project is built using \textcolor{red}{JavaScript}, HTML and CSS in contrast to our development plan using \textcolor{red}{Python} and the Pygame library. Since we are using an OOP language, we will be able to create classes for different components of the snake game such as \textcolor{red}{the snake's body drawn in blocks, and snake's food.} The hardest part of the implementation will be the movement of the snake according to the user's keyboard inputs, and second to that would be the process of expanding the snake once a food item is captured. Besides that, the interface may be difficult to implement in \textcolor{red}{Python using the Pygame library to make it engaging.}\\
Once our game application has been developed the next part would be to test the project and for that we will be using Pytest, since our backend language is \textcolor{red}{Python} this will help us test all possible functions and \textcolor{red}{functional requirements}. The functions that will be difficult to test would be to see if the snake eats the food, does the food appear at random locations after eaten by the snake and if the snake tries to leave the borders, will the game end. Portability will have to be taken into consideration since the application is being built for \textcolor{red}{different Operating System}. However, it can be compiled and run on any system as long as the necessary files and libraries are download.
\textcolor{blue}{\subsection{POC Demo}
......
No preview for this file type
......@@ -27,8 +27,9 @@
2018-09-20 & Vaibhav & Made the LaTeX file and wrote the section with what the Problem is\\
2018-09-20 & Usman & Added the Importance of Problem section while formatting the LaTeX\\
2018-09-21 & Andy Hameed & Formatted LaTeX file and added Context section, giving the final editing to the document\\
\textcolor{blue}{2018-10-09} & Andy Hameed & Edited doc to reflect web app to desktop app decision change\\
\textcolor{red}{2018-10-09} & Andy Hameed & Edited doc to reflect web app to desktop app decision change\\
\textcolor{red}{2018-12-02} & Vaibhav Chadha & Revision one changes to make the document better.\\
\textcolor{red}{2018-10-09} & Usman Irfan & Edited Importance of the Problem\\
\bottomrule
\end{tabularx}
\end{table}
......@@ -39,15 +40,14 @@
\subsection*{The Problem}
Almost everyone nowadays relies on a computer as a multipurpose tool for research, video streaming, gaming and many other tasks. With the emergence of fast computing, gaming has become a popular pastime activity and a source of entertainment for many. However, not everyone has a device powerful enough to support extensive game applications. A simple, memory efficient application of the Snake game allows it to be accessible for gamers without the need for extensive hardware or a high-performance computer. \textcolor{blue}{Our team, VUA30, will be creating a desktop application for the well-known Snake game with new enhancements and features. This competitive and addictive game can allow the user to play at \textcolor{red}{different levels and challenge their own highscore} }
Almost everyone nowadays relies on a computer as a multipurpose tool for research, video streaming, gaming and many other tasks. With the emergence of fast computing, gaming has become a popular pastime activity and a source of entertainment for many. However, not everyone has a device powerful enough to support extensive game applications. A simple, memory efficient application of the Snake game allows it to be accessible for gamers without the need for extensive hardware or a high-performance computer. \textcolor{red}{Our team, VUA30, will be creating a desktop application for the well-known Snake game with new enhancements and features. This competitive and addictive game can allow the user to play at \textcolor{red}{different levels and challenge their own highscore} }
\subsection*{Importance of the Problem}
Buying a computing device with high storage and faster performance can be out of budget. Complicated software covers up all the storage and the user is bound to use these applications as opposed to downloading other software. The importance of the redevelopment of The Snake is to save computing \textcolor{red}{device's} personal storage and allow the user to play a game 24/7 with strong performance, even offline. \textcolor{blue}{Creating a desktop version of the snake game can fit into the category of downloadable calssical games such as the solitaire suite. The recreation of this game will allow the user to enjoy the classical game anytime and anywhere as long as they have installed the application. Improving aspects such as graphics and custom speed will also make the game more interesting. We would like to add more features to the game to make it more customizable and help people enjoy the classical game in an exciting and new way.}
Buying a computing device with high storage and faster performance can be out of budget. Complicated software covers up all the storage and the user is bound to use these applications \textcolor{red}{without} downloading other software. The importance of the redevelopment of The Snake is to save computing \textcolor{red}{device's} personal storage and allow the user to play a game 24/7 with strong performance, \textcolor{red}{even offline}. \textcolor{red}{ Creating a desktop application of the snake game can fit into the category of classic games such as the solitaire suite. The recreation of this game will allow the user to enjoy the traditional game anytime and anywhere as long as they have installed the application. Improving aspects such as graphics and custom speed will also make the game more interesting. We would add more features to the game to make it more customizable and let people enjoy the classic game impressively.}
\subsection*{Context}
The stakeholders are mainly the gaming audience, the older generation of game enthusiasts, youth and teens. Although the game can be played by anyone, it is targeted towards the audience mentioned above who are most invested in the game. The environment is native app development using Python and the Pygame library. This provides less flexibility than web API's but there still exists many useful Python libraries which can be used such as Pygame.
\end{document}
No preview for this file type
......@@ -41,6 +41,7 @@
Oct 5, 2018 & 1.0 & Andy worked on Project Drivers and Project Issues. Usman worked on Functional requirements. Vaibhav worked on Non-Functional Requirements\\
\textcolor{red}{Dec 2, 2018} & 1.1 & Vaibhav is performing revision 1 in order to improve the quality of the document\\
\textcolor{blue}{Dec 2, 2018} & 1.1 & Andy edited the formatting issues stated in feedback for Revision 1\\
\textcolor{red}{Dec 2, 2018} & 1.1 & Usman is performing revision 1 in order to improve the quality of the document\\
\bottomrule
\end{tabularx}
\end{table}
......@@ -164,9 +165,8 @@ $\bullet$ Development Plan \date{28/09/18}\\
\subsubsection{Work Partitioning}
%breakdown your task into sub-task e.g. break logic and user interface
The desktop application involves different processes to successfully run: making a user-interface so the user can interact with the application, the logic behind the user-interface that can handle all the inputs given by the user and outputs the result according to the requirements.
These tasks can be divided into sub-task. For example, the system uses the microphone as an input, so whenever the sake completes a functional requirement (the requirements are described below) it will output an audio to make the game much more interesting. Another example would be, the movement of the snake and it get larger would be done by the logic at the back-end and its output will be displayed on the screen so the user can continue playing.
Tasks such as displaying the food, making snake appear at random locations in the beginning, etc. should all be divided and can be worked individually as this would more efficient to complete and the developer would know how to test these functions.
The desktop application involves different processes to successfully run: making a user-interface so the user can interact with the application, \textcolor{red}{Back-End Development} that can handle all the inputs given by the user and \textcolor{red}{updates the interface} according to the requirements.
These tasks can be divided into sub-task. For example, \textcolor{red}{the system uses a mouse as an input, so whenever the user presses a button on the interface from its computer's mouse, there is an update in the display making the user engaged to the application. Tasks such as displaying the food, making the snake appear at random locations, in the beginning, should all be divided and can be accomplished individually by the developers, this would be more efficient to complete the project, and the respective developer would know how to test the functions they created}.
\subsubsection{Individual Product Use Cases}
%
The user can use the system-to-be (the desktop application) to entertain themselves when they are bored. They can use the system to improve their response time, with playing the game in difficulty modes it can be more challenging and the user has to be fast. In addition, the desktop application would be a fun means of entertainment between friends as they can play turn-by-turn and challenge each other.
......@@ -174,65 +174,59 @@ The user can use the system-to-be (the desktop application) to entertain themsel
$\bullet$ Requirement number: FR(Functional Requirement)1\\
When the user sees the interface it can start the game by pressing any button key.\\
Rationale: If the user presses any button and the game does not work as it is expected to be.\\
\textcolor{red}{When the user sees the interface, it can select the buttons on the screen by using the computer's mouse.}\\
$\bullet$ Requirement number: FR2 \\
User's can press F11 key to play the desktop application in Full screen mode.\\
$\bullet$ Requirement number: FR2\\
The user can press the UP key to move the snake's direction in the upwards direction.\\
$\bullet$ Requirement number: FR3\\
The user can press the UP key to move the snake's direction in the upwards direction.\\
The user can press the DOWN key to move the snake's direction in the downwards direction.\\
$\bullet$ Requirement number: FR4\\
The user can press the DOWN key to move the snake's direction in the downwards direction.\\
The user can press the LEFT key to move the snake's direction in the left direction.\\
$\bullet$ Requirement number: FR5\\
The user can press the LEFT key to move the snake's direction in the left direction.\\
The user can press the \textcolor{red}{RIGHT} key to move the snake's direction in the right direction.\\
$\bullet$ Requirement number: FR6\\
The user can press the LEFT key to move the snake's direction in the right direction.\\
The game should display the user's highest score.\\
$\bullet$ Requirement number: FR7\\
The game should display the user's highest score.\\
The initial location of the snake should be random whenever the user starts the game or when it restarts.\\
$\bullet$ Requirement number: FR8\\
The initial location of the snake should be random whenever the user starts the game or when it restarts.\\
The user has the option to play in three different modes: \textcolor{red}{easy, intermediate and advanced.}\\
$\bullet$ Requirement number: FR9\\
The user has the option to play in three different modes: easy, medium and hard.\\
\textcolor{red}{The desktop application shall provide a facility to play the game in different themes, e.g., Dark or Light, or choose the random option to select either theme.}\\
$\bullet$ Requirement number: FR10\\
The game should display the user's highest score.\\
\textcolor{red}{When the snake eats its food, its length should be increased by 3 units. For instance, when the game is started the snake’s length is only 1 unit, but after eating a block of food, its new length should be 4 units.}\\
$\bullet$ Requirement number: FR11\\
The desktop application provides a facility to toggle in different themes, e.g. Dark to Light.\\
\textcolor{red}{Once the snake eats its food, the food should reappear on the screen.}\\
$\bullet$ Requirement number: FR12\\
The desktop application provides a facility to toggle in different themes, e.g. Dark to Light.\\
\textcolor{red}{When the user is playing the game in easy mode, the snake is allowed to move within the screen size and can pass the boundaries (the window screen edges), if the snake traverses the boundary it should reappear from the opposite direction.}\\
$\bullet$ Requirement number: FR13\\
When the snake eats its food its length should be increased by 5 units. For instance, when the game is started and the snake's length is only 1 unit, but after eating a block of food its new length should be 6 units.\\
\textcolor{red}{When the user is playing the game in either intermediate or advanced mode, the snake is allowed to move within the screen size and cannot pass the boundaries (the window screen edges), if the snake traverses the boundary it should die, and a message should prompt on the screen to restart the game.}
$\bullet$ Requirement number: FR14\\
By pressing the spacebar key the game should be paused.\\
\textcolor{red}{When the user is playing the game in advanced mode, the game shall offer a maze within the Gameplay to restrict the snake's location and make it more challenging.}
$\bullet$ Requirement number: FR15\\
By pressing the spacebar key the game should be resumed, only if the game was paused initially.\\
If the snake bites itself, the game should be over and a message should prompt on the screen to restart the game.\\
$\bullet$ Requirement number: FR16\\
Snake's food should be randomly placed on the screen in the beginning of the game, once the snake eats its food, the food should reappear on the screen.\\
\textcolor{red}{The highest score of the user shall be saved in a text file.}\\
$\bullet$ Requirement number: FR17\\
The snake is allowed to move around in a certain space, if the snake crosses that space it should die and a message should prompt on the screen to restart the game.\\
\textcolor{red}{The user can view their highest score from the main menu by pressing the Highscore button.}\\
$\bullet$ Requirement number: FR18\\
If the snake bites itself, the game should be over and a message should prompt on the screen to restart the game.\\
$\bullet$ Requirement number: FR19\\
If the user is successful in making the snake eat 10 food units consecutively, a food unit with more value should be displayed on the screen that would give the snake more points but will increase its length with the same amount, as previously stated.\\
\textcolor{red}{The color of the snake changes when a different theme is selected.}\\
$\bullet$ Requirement number: FR20\\
The snake should change its colour when it dies.\\
\section{Non-functional Requirements}
......
No preview for this file type
......@@ -45,6 +45,7 @@
10/25/2018 & 1.0 & Usman added section 3.1, Vaibhav added section 3.2, Andy added section 4. \\
10/26/2018 & 1.0 & Andy added section 1 and 7, Vaibhav added section 2 and 5, Usman added section 6.\\
\textcolor{red}{12/2/2018} & 1.1 & Vaibhav is doing the revision 1 in order to improve the documents quality\\
\textcolor{red}{12/2/2018} & 1.1 & Usman is doing the revision 1 in order to improve the documents quality\\
\bottomrule
\end{tabularx}
\end{table}
......@@ -138,36 +139,48 @@ See \href{https://gitlab.cas.mcmaster.ca/hameea1/se3xa3/tree/master/BlankProject
\subsubsection{Testing Functions \& Methods}
\item{\textbf{TID1}\\}
Type: Functional, Dynamic, manual
Initial State: The desktop application starts waiting for the user to enter a command to begin.
Input: The user presses any button key.
Output: The desktop application begins moving the snake towards the Right.
How test will be performed: The test will be done dynamically, that means once the program will be executed the developer will press any key to see if it would run the game, making the snake move.
\textcolor{red} {Type: Functional, Dynamic, manual\\
Initial State: The desktop application starts waiting for the user to select a game mode to begin.\\
Input: The user selects one of the game modes from the main menu.\\
Output: The desktop application moves to the next page by displaying the themes.\\
How the test will be performed: The test will be done dynamically, that means once the program will be executed the tester would select a difficulty level and see if the page gets updated by displaying different themes.}
\item{\textbf{TID2}\\}
Type: Functional, Dynamic, Manual
Initial State: The desktop application executes and displays a screen with a headline \textbf{High Score:} in the top
Input: NULL
\textcolor{red} {Type: Functional, Dynamic, manual\\
Initial State: The desktop application is at the theme mode and requires user input to select an input and display the game mode.\\
Input: The user selects one of the themes from the theme page interface.\\
Output: The desktop application moves to the next page by displaying the gameplay interface.\\
How the test will be performed: The test will be done dynamically, that means once the program will be executed the tester would select a theme and see if the page gets updated by displaying the gameplay.}
Output: The game would display the highest score of the user from the day they started to play till the present date.
\item{\textbf{TID3}\\}
Type: Functional, Dynamic, Manual
How test will be performed: When the game is played for the first time its Highest Score should be 0, the developer plays for a while and tests the score they made by playing should be the highest score when playing the second time.\\
When the game is restarted or turned off the game still holds the highest score.\\
Two more scenarios are present to test the highest score requirement. Take for example a current high score of 85:\\
1. The user beats the highest score, and the highest score is updated to the user's score when playing the next time.\\
2. The user is not able to defeat the highest score and the highest score will still be 85 when they play the game next time.
\textcolor{red} {Type: Functional, Dynamic, manual\\
Initial State: The desktop application executes and displays a ``Highscore" button on the bottom left of the main menu.\\
Input: The user selects the ``Highscore" button.Output: The desktop application moves to the next page by displaying the gameplay interface.\\}
Output: The application would display the highest score of the user from the day they started to play till the present date.
\item{\textbf{TID3}\\}
How the test will be performed: The test will be done dynamically, that means once the program will be executed the tester would select a theme and see if the page gets updated by displaying the gameplay.
\item{\textbf{TID4}\\}
Type: Functional, Dynamic, manual
Initial State: The desktop application starts waiting for the user to enter a command to begin.
Input: The user presses any button key.
Output: The desktop application begins moving the snake towards the respective direction.
How the test will be performed: The test will be done dynamically, that means once the program will be executed the developer will press any key to see if it would run the game, making the snake move.
\item{\textbf{TID5}\\}
Type: Functional, Dynamic, Manual
......@@ -179,7 +192,7 @@ Output: The snake displays the snake at random location when played the next tim
How test will be performed: The user can track the location of the snake the first time the game is played. The game should be restarted to ensure that the snake's position changes every time the game starts.
\item{\textbf{TID4}\\}
\item{\textbf{TID6}\\}
Type: Functional, Dynamic, Manual
......@@ -192,19 +205,8 @@ Output: The food reappears on the screen at a random location when the snakes ea
How test will be performed: The developer will test this requirement by moving the snake's head location equal to the food's location. When the snake eats the food, instantly another food should display on the screen at a random location.
\subsubsection{Testing of Keyboard/Mouse Interactions}
\item{\textbf{TID5}\\}
Type: Functional, Dynamic, Manual
Initial State: The desktop application starts waiting for the user to enter a command to begin.
Input: The user presses F-11 key.
Output: The desktop application screen is changed to full-screen mode.
How test will be performed: The test will be done dynamically, that means once the program will be executed the developer will press the F-11 key to test if the size of the screen changes to full-screen mode.
\item{\textbf{TID6}\\}
\item{\textbf{TID7}\\}
Type:Functional, Dynamic, Manual
......@@ -216,7 +218,7 @@ Output: The snake in the game would moves up by one-unit length.
How test will be performed: The test will be done dynamically, that means once the program will be executed the developer will press the UP key to test if the snake moves in the upward direction.
\item{\textbf{TID7}\\}
\item{\textbf{TID8}\\}
Type: Functional, Dynamic, Manual
......@@ -229,7 +231,7 @@ Output: The snake in the game would moves down by one-unit length.
How test will be performed: The test will be done dynamically, that means once the program will be executed the developer will press the DOWN key to test if the snake moves in the downward direction.
\item{\textbf{TID8}\\}
\item{\textbf{TID9}\\}
Type: Functional, Dynamic, Manual
......@@ -241,7 +243,7 @@ Output: The snake in the game would moves left by one-unit length.
How test will be performed: The test will be done dynamically, that means once the program will be executed the developer will press the LEFT key to test if the snake moves in the left direction.
\item{\textbf{TID9}\\}
\item{\textbf{TID10}\\}
Type: Functional, Dynamic, Manual
......@@ -253,29 +255,18 @@ Output: The snake in the game would moves right by one-unit length.
How test will be performed: The test will be done dynamically, that means once the program will be executed the developer will press the RIGHT key to test if the snake moves in the right direction.
\item{\textbf{TID10}\\}
\item{\textbf{TID11}\\}
Type: Functional, Dynamic, Manual
Initial State: The desktop application executes and displays three modes to be played.
Type: Functional, Dynamic, Manual
Initial State: The desktop application executes and displays three modes to be played.
Input: Mouse Cursor
Output: The application should open the specific mode the user has requested to play.
How test will be performed: Different modes in the game will be opened using the mouse cursor, their display or speed should be different from other modes. Easy having the slowest speed and allowing the snake to exit from the one-direction boundary and enter from the other direction of the boundary (e.g. leaving from right side boundary and entering from the left side boundary). While playing the hard mode, the speed should be much faster than the Easy mode, and would not allow the snake to cross the boundary. If the snake touches the boundary the snake should die and terminating the game.
\item{\textbf{TID11}\\}
Type: Functional, Dynamic, Manual
Initial State: The desktop application executes and displays three modes to be played.
Input: Mouse Cursor
How test will be performed: Different modes in the game will be opened using the mouse cursor, their display or speed should be different from other modes. Easy having the slowest speed and allowing the snake to exit from the one-direction boundary and enter from the other direction of the boundary (e.g. leaving from right side boundary and entering from the left side boundary). While playing the hard mode, the speed should be much faster than the Easy mode, and would not allow the snake to cross the boundary. If the snake touches the boundary the snake should die and terminating the game.
Output: Changes the theme of the game application.
How test will be performed: If the game is initially set to Light mode. On clicking the Theme button the game changes the theme from Light to Dark theme.
\item{\textbf{TID12}\\}
......@@ -287,58 +278,18 @@ Input: The user presses the Direction keys to control the snake
Output: The length of the snake should not equal to one-unit length when it dies (Hard mode would be an exception).
How test will be performed: The developer moves the snake by pressing the direction keys. When the snake's head location equals the food location, its length should be increased by five unit-length. When the snake dies its increase in length should be divisible by 5.
\item{\textbf{TID13}\\}
Type: Functional, Dynamic, Manual
Initial State: The game is already executed, and the user is playing the game.
Input: The user presses the Space key to pause the snake.
Output: The snake's movement has been stopped.
How test will be performed: The developer will test this requirement by pressing the Spacebar key in between the game, will track down's snake location and see if the snake stops on the screen of the Spacebar key is pressed for the first time.
To test the pause movement, we can think of pausing and resuming of the game as two states. If the Spacebar key is pressed odd time it will be in the pause state else, it will be in the resume state.
How test will be performed: The developer moves the snake by pressing the direction keys. When the snake's head location equals the food location, its length should be increased by five unit-length. When the snake dies its increase in length \textcolor{red}{its length should be increased by three unit-length}.
\item{\textbf{TID14}\\}
Type: Functional, Dynamic, Manual
Initial State: The snake's movement has been stopped.
Input: The user presses the Space key to resume the snake's movement.
Output: The snake's movement has been resumed.
How test will be performed: The developer will test this requirement by pressing the spacebar key in between the game, will track down's snake location and see if the snake moves on the screen if the spacebar key is pressed for the second time.
To test the pause movement, we can think of pausing and resuming of the game as two states. If the spacebar key is pressed odd time it will be in the pause state else, it will be in the resume state.
\subsubsection{Testing Game Ending}
\item{\textbf{TID15}\\}
Type: Functional, Dynamic, Manual
Initial State: The snake is not one-unit length..
Input: NULL.
Output: The screen displays a screen biting itself, and a message prompts on the screen display "GAME OVER!".
How test will be performed: The developer will test this requirement by moving the snake's head location equal to the snake's body location. When the snake eats its body the snake's movement should stop and will be able to see the error message.
\item{\textbf{TID16}\\}
\item{\textbf{TID13}\\}
Type: Functional, Dynamic, Manual
Initial State: The snake is red colour
Initial State: The snake is not one-unit length.
Input: NULL.
Output: The screen displays a screen biting itself in red colour .
How test will be performed: The developer will test this requirement by intentionally killing the snake. The function should change the snake's colour from green to red. If the snake's colour is red before replaying the game, the function passes its test (exception: the user presses the restart button and doesn't want to play the game till the end).
Input: NULL.\\
\textcolor{red}{Output: The screen displays a screen biting itself, and a message prompts on the screen with various options to allow the user to play the game again or go to the main menu.\\
How the test will be performed: The developer will test this requirement by moving the snake’s head location to the snake’s body location. When the snake eats its body the snake’s movement should stop and will be able to see the error message.}
\end{enumerate}
......@@ -571,7 +522,8 @@ Currently, we have the following tests that compare to the existing comparison:
\section{Unit Testing Plan}
The PyUnit testing framework would be used to test our desktop application.
\subsection{Unit testing of internal functions}
The PyUnit testing framework will be used to test our source code's functions, this is an automated testing unit, and it provides classes which can ease different testing functions. By using PyUnit we can check the robustness of our program, if wrong inputs are given will the program be able to handle such cases without crashing. Besides, the requirement of the program can be tested to see if our program matches with the functional and non-functional requirements of the program. For example, the function that moves the snake in X-axis and Y-axis can be tested by entering the snake's X, Y location, the axis it wants to go and its direction (up or down for y-axis, and left or right for x-axis). The goal is to test as many functions examining all possible cases which can make our application run smoothly without crashing. \subsection{Unit testing of output files}
The PyUnit testing framework will be used to test our source code's functions, this is an automated testing unit, and it provides classes which can ease different testing functions. By using PyUnit we can check the robustness of our program, if wrong inputs are given will the program be able to handle such cases without crashing. Besides, the requirement of the program can be tested to see if our program matches with the functional and non-functional requirements of the program.
\subsection{Unit testing of output files}
The testing of the output files through unit testing will tell the developers if all the test cases designed by them run efficiently. The snake's movement would be compared to the actual output if the user is pressing the UP key and the snake is moving in the respective direction it would pass the unit testing. Testing the output files can also help us to find that if different modes of the game are selected then different rules of the games should be followed. The game being played in the Hard mode could be tested that the snake is not allowed to cross boundaries and this could be compared with automated testing allowing us to know if our output files have passed their unit test.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment