Clean up qqmlstatemachinemetatype test


We need to expose the test data in the CMakeLists.txt so that
qmlimportscanner can pick it up. We also want to see the error string if
the instantiation fails.

This test only worked on Android because of a different bug that makes
Android tests pass if the data collection fails.

Pick-to: 6.2 6.3
Task-number: QTBUG-102252
Change-Id: I0c7dee57eca9ab2dedf7818c91ce55e32d658c42
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
commit2962ea59fb7e7763f8719905b76a932b4a7ad53b
parente847c99555e057ef7646bd572130af9da9b92cb5
authorUlf Hermann <ulf.hermann@qt.io>
committerUlf Hermann <ulf.hermann@qt.io>
commit timeTue, 5 Apr 2022 11:08:49 +0200