How To Run jUnit Tests » History » Version 5
Sergey Smolov, 09/21/2018 05:29 PM
1 | 1 | Sergey Smolov | h1. How To Run jUnit Tests |
---|---|---|---|
2 | |||
3 | h2. Prerequisites |
||
4 | |||
5 | The most preferable OS is *Linux*. We prefer Debian-based distros, like Ubuntu. |
||
6 | |||
7 | 4 | Sergey Smolov | To run the project's jUnit tests the *gcc-mips-linux-gnu* package should be installed. Create _MIPS64_TCHAIN_ environment variable that points to a directory, that contains the _bin_ subdirectory with the toolchain components. |
8 | 1 | Sergey Smolov | |
9 | 5 | Sergey Smolov | See the QEMU4V emulator's "Installation Guide":https://forge.ispras.ru/projects/qemu4v/wiki/Installation, because this is used in testing. |
10 | 1 | Sergey Smolov | |
11 | h2. Overview |
||
12 | |||
13 | The *MicroTESK for MIPS* project's "Git repository":https://forge.ispras.ru/projects/microtesk-mips64/repository contains a number of JUnit tests. The typical JUnit test contains the following sequence of stages: |
||
14 | 2 | Sergey Smolov | |
15 | 1 | Sergey Smolov | # Template-based test program generation - the result of this stage is _<notextile>*</notextile>.s_ MIPS assembly file and a _<notextile>*</notextile>.log_ trace file; |
16 | 2 | Sergey Smolov | # Test program compilation - the result of this stage is a binary ELF image of the test program; |
17 | # Test program emulation - the result of this stage is a _<notextile>*</notextile>-qemu.log_ trace file. |
||
18 | |||
19 | In the nearest future the one more stage will be added: |
||
20 | # Execution trace comparison - the _<notextile>*</notextile>.log_ MicroTESK trace and the _<notextile>*</notextile>-qemu.log_ QEMU4V trace will be compared, a report will be generated. |
||
21 | 1 | Sergey Smolov | |
22 | To run the project tests, enter the project directory that contains the _gradlew_ script, and do the following: |
||
23 | <pre> |
||
24 | ./gradlew test |
||
25 | </pre> |