diff options
Diffstat (limited to 'report/progression.tex')
-rw-r--r-- | report/progression.tex | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/report/progression.tex b/report/progression.tex index cf4f3d2..24c5d7a 100644 --- a/report/progression.tex +++ b/report/progression.tex | |||
@@ -230,10 +230,37 @@ player is at the starting point. | |||
230 | 230 | ||
231 | \subsection{tests} | 231 | \subsection{tests} |
232 | 232 | ||
233 | In the current version of the game, the outputs of commands such as help or quit | ||
234 | might be easily tested. Furthermore, movement from rooms to rooms, and arising | ||
235 | modifications on the model, can also be candidates for testing. | ||
236 | |||
233 | \subsubsection{Automatic tests} | 237 | \subsubsection{Automatic tests} |
234 | 238 | ||
239 | Functionalities of the program can be tested automatically using unit testing | ||
240 | for classes and methods, and interactive testing to simulate the user's | ||
241 | interactions. | ||
242 | |||
243 | Unit tests will later be implemented using the JUnit testing framework. | ||
244 | |||
245 | User interactions like command input can be simulated by reading and | ||
246 | interpreting commands from a text file. | ||
247 | |||
235 | \subsection{test command} | 248 | \subsection{test command} |
236 | 249 | ||
250 | The test command was implemented by modifying the Console view with commit | ||
251 | 967f40d71. Instead of reading commands from the user's input from the console, | ||
252 | the Scanner reads the commands from a text file. | ||
253 | |||
254 | This functionnality was not implemented as a command inside the game, but as a | ||
255 | command line flag that can be used by executing the program from a terminal with | ||
256 | ``--file <file path>''. | ||
257 | |||
258 | \subsubsection{test files} | ||
259 | |||
260 | Three test files were created. The first one tests simple commands such as help | ||
261 | and quit, the second one explores all rooms, and the last one executes all actions | ||
262 | to win the game. | ||
263 | |||
237 | 264 | ||
238 | \section{Zuul with items v2} | 265 | \section{Zuul with items v2} |
239 | 266 | ||