|
1 isEmpty(TEMPLATE):TEMPLATE=app |
|
2 CONFIG += qt warn_on console depend_includepath |
|
3 |
|
4 qtAddLibrary(QtTest) |
|
5 |
|
6 symbian:{ |
|
7 TARGET.EPOCHEAPSIZE = 0x100000 0x2000000 |
|
8 # DEFINES += QTEST_NO_SPECIALIZATIONS |
|
9 TARGET.CAPABILITY="ALL -TCB" |
|
10 RSS_RULES ="group_name=\"QtTests\";" |
|
11 } |
|
12 |
|
13 # prefix test binary with tst_ |
|
14 !contains(TARGET, ^tst_.*):TARGET = $$join(TARGET,,"tst_") |
|
15 |
|
16 |
|
17 check.files = |
|
18 check.path = . |
|
19 !isEmpty(DESTDIR): check.commands = cd ./$(DESTDIR) && |
|
20 macx: check.commands += ./$(QMAKE_TARGET).app/Contents/MacOS/$(QMAKE_TARGET) |
|
21 else:unix: check.commands += ./$(QMAKE_TARGET) |
|
22 else:win32: { |
|
23 CONFIG(debug, debug|release):check.commands += $(DESTDIR_TARGET) |
|
24 else:check.commands += $(DESTDIR_TARGET) |
|
25 } |
|
26 embedded: check.commands += -qws |
|
27 QMAKE_EXTRA_TARGETS += check |
|
28 |
|
29 !debug_and_release|build_pass { |
|
30 check.depends = first |
|
31 } else { |
|
32 check.CONFIG = recursive |
|
33 # In debug and release mode, only run the test once. |
|
34 # Run debug if available, release otherwise. |
|
35 debug_and_release { |
|
36 check.target = dummy_check |
|
37 check.recurse_target = check |
|
38 debug { |
|
39 real_check.depends = debug-check |
|
40 real_check.target = check |
|
41 QMAKE_EXTRA_TARGETS += real_check |
|
42 } else { |
|
43 real_check.depends = release-check |
|
44 real_check.target = check |
|
45 QMAKE_EXTRA_TARGETS += real_check |
|
46 } |
|
47 } |
|
48 } |
|
49 |
|
50 target.path += $$[QT_INSTALL_PREFIX]/tests/qt4 |
|
51 INSTALLS += target |