Tom, It looks like you did not include the build path in the unit test build configuration. I'm getting a build error when the unit test is enabled:
[ 33%] Building CXX object tests/pns/CMakeFiles/test_node.dir/test_node.cpp.obj In file included from C:/msys64/home/wstambaugh/src/kicad-trunk/pcbnew/pcbnew.h:33:0, from C:/msys64/home/wstambaugh/src/kicad-trunk/pcbnew/class_track.h:34, from C:/msys64/home/wstambaugh/src/kicad-trunk/pcbnew/router/pns_via.h:28, from C:/msys64/home/wstambaugh/src/kicad-trunk/pcbnew/router/pns_line.h:33, from C:/msys64/home/wstambaugh/src/kicad-trunk/pcbnew/router/pns_segment.h:32, from C:/msys64/home/wstambaugh/src/kicad-trunk/pcbnew/router/pns_joint.h:31, from C:/msys64/home/wstambaugh/src/kicad-trunk/pcbnew/router/pns_node.h:37, from C:/msys64/home/wstambaugh/src/kicad-trunk/tests/pns/test_node.cpp:7: C:/msys64/home/wstambaugh/src/kicad-trunk/include/fctsys.h:37:20: fatal error: config.h: No such file or directory compilation terminated. make[2]: *** [tests/pns/CMakeFiles/test_node.dir/build.make:63: tests/pns/CMakeFiles/test_node.dir/test_node.cpp.obj] Error 1 On 9/7/2016 12:17 PM, Tomasz Wlostowski wrote: > Hi, > > This patch adds possibility to build C++ tests for pcbnew, using > Boost.Test framework. I intended it primarily to make tests for the P&S, > which I used to develop out-of-tree before. > > Since Kicad's codebase is rather monolithic, testing/refactoring > anything drags in pretty much everything else in the code as a > dependency. This causes long rebuild and linking times, which I find > very annoying. Also, while developing new features, most of the time is > spent linking pcbnew and clicking in the GUI to trigger the particular > feature. > > For that reason I decided to link all the test cases directly to the > _pcbnew_kiface library and skip pcbnew's dependency scanning when > building tests. I'm also preparing a bare PCB test window for verifying > interactive/graphical operations without rebuilding pcbnew as a whole app. > > I've attached the patch (set the KICAD_BUILD_TESTS=ON option to enable). > There's one trivial unit test included as an example. Let me know if > such solution would be acceptable. > > Cheers, > Tom > > > > _______________________________________________ > Mailing list: https://launchpad.net/~kicad-developers > Post to : kicad-developers@lists.launchpad.net > Unsubscribe : https://launchpad.net/~kicad-developers > More help : https://help.launchpad.net/ListHelp > _______________________________________________ Mailing list: https://launchpad.net/~kicad-developers Post to : kicad-developers@lists.launchpad.net Unsubscribe : https://launchpad.net/~kicad-developers More help : https://help.launchpad.net/ListHelp