]> Git Repo - VerusCoin.git/blob - doc/unit-tests.md
Merge pull request #2104 from al42and/listreceivedbyaddress_txids
[VerusCoin.git] / doc / unit-tests.md
1 Compiling/running bitcoind unit tests
2 ------------------------------------
3
4 bitcoind unit tests are in the `src/test/` directory; they
5 use the Boost::Test unit-testing framework.
6
7 To compile and run the tests:
8
9         cd src
10         make -f makefile.unix test_bitcoin  # Replace makefile.unix if you're not on unix
11         ./test_bitcoin   # Runs the unit tests
12
13 If all tests succeed the last line of output will be:
14 `*** No errors detected`
15
16 To add more tests, add `BOOST_AUTO_TEST_CASE` functions to the existing
17 .cpp files in the test/ directory or add new .cpp files that
18 implement new BOOST_AUTO_TEST_SUITE sections (the makefiles are
19 set up to add test/*.cpp to test_bitcoin automatically).
20
21
22 Compiling/running Bitcoin-Qt unit tests
23 ---------------------------------------
24
25 Bitcoin-Qt unit tests are in the src/qt/test/ directory; they
26 use the Qt unit-testing framework.
27
28 To compile and run the tests:
29
30         qmake bitcoin-qt.pro BITCOIN_QT_TEST=1
31         make
32         ./bitcoin-qt_test
33
34 To add more tests, add them to the `src/qt/test/` directory,
35 the `src/qt/test/test_main.cpp` file, and bitcoin-qt.pro.
This page took 0.025877 seconds and 4 git commands to generate.