smart test in its setup updates the rpm index using the build environment. When exporting the tests this is not available and there is a traceback when loading the tests. This happens because the smart test module imports bb and oe, not available in exported tests.
With dnf planned for 2.3 release, I don't know if is worth the time to fix this test.
linking to the dnf replacing bug
The difficult part here is oe.utils.multiprocess_exec, which would have to be reproduced somewhere outside the context of "oe" and "bb". The indexing commands are called with this function so that the tests run quicker. Paul mentioned that we could skip multiprocess if INHERIT contains "testexport". There's no explicit need to use multiprocess in this context. The rest of the calls to "bb" and "oe" could be abstracted out to oeRuntimeTest.tc with some work.
I rewrote smart tests for dnf, so if you explain to me what 'exporting the tests' means and how to do it, I can check if it's still a valid problem.
Exporting tests is a functionality of the runtime framework, the idea is to put all the libraries and test in a directory and you can copy this folder to another host and execute the test; it is implemented in testexport bbclass. testimage and testexport execute the same tests. So, the problem here is that in dnf tests we setup a local repository in the host running the test based paths (WORKDIR) that won't be necessarily available in a host without build environment. Thinking about this a way to achieve this is avoid the setup of the repository in the test itself and do it in the testimage class. And in testexport you would need to specify the url of the repository server.
Alex, should we mark this as resolved/obsolete or it is still valid?
To be honest I have no idea. Can you provide a clear set of steps to reproduce this?
based on comment 2 and comment 7, resolving as obsolete.