Cvtest not working

In file included from test_blenders.cpp:42: test_precomp.hpp:7:10: fatal error: opencv2/ts.hpp: No such file or directory 7 | #include “opencv2/ts.hpp” | ^~~~~~~~~~~~~~~~ compilation terminated

It is saying this error again and again even though this file directory is present?

disable building of tests then

  • which opencv version is it ?
  • did you enable BUILD_TESTS in cmake ?
  • are you trying to build a testcase AFTER installing libs/headers ? (it won’t install the test suite headers along with other opencv headers !)

well, you’re supposed to do the opposite, setBUILD_TESTS=ON, and let it build the tests along with the libs.

if you want to build tests later, you need to copy the ts.lib & the ts header folder manually

please, describe exactly, what you’re doing, and give exact output.

above post is useless, sorry ;(

i still do not see any proper error msg ,
however, most tests need additional data from here
(you need to clone another gh repo), e.g. the missing xml file is here

main problem is here:

g++ test_operations.cpp -o test_operations

how do you expect this to work, ever ?
(missing include / library paths, opencv / test libs, etc.)

please give this a break, & consult some basic c++ tutorials

p.s. i took the liberty to remove your useless screenshots (500kb).
please DO NOT post images of text anywhere on the net, thank you.

┌──(aashka㉿Technology)-[~/opencv/modules/core/test]
└─$ g++ test_operations.cpp -o test_operations -I/home/aashka/opencv/modules/core/test/
In file included from test_operations.cpp:43:
test_precomp.hpp:7:10: fatal error: opencv2/ts.hpp: No such file or directory
7 | #include “opencv2/ts.hpp”
| ^~~~~~~~~~~~~~~~
or
┌──(aashka㉿Technology)-[~/opencv/modules/core/test]
└─$ g++ test_operations.cpp -o test_operations -I/home/aashka/opencv/modules/core/include -I/home/aashka/opencv/build/include -L/home/aashka/opencv/build/lib -lopencv_core

In file included from test_operations.cpp:43:
test_precomp.hpp:7:10: fatal error: opencv2/ts.hpp: No such file or directory
7 | #include “opencv2/ts.hpp”
| ^~~~~~~~~~~~~~~~
compilation terminated.

compilation terminated.
i send you the screenshot of this only i wrote the library and all then only error came ,i didnt wrote that way it was showing in vscode the way you quote out , if we run via the run symbol it is showing “g++ test_operations.cpp -o test_operations” way only,i didnt wrote it like this , i wrote the complete path in terminal than ran the code and the the error was shown i didnt did it that way ,sorry about the screenshot i didnt knew , i was not getting why the error is coming thats why i send

probably needs `-I/home/aashka/opencv/modules/ts/include/’ , too ?

also -lopencv_ts (and whatever library path you need to add for it)

Okay I will try it , Thank you