Bug 496162

Summary: mymoneyxmlreader-tests fails when running from build directory
Product: [Applications] kmymoney Reporter: Ralf Habacker <ralf.habacker>
Component: buildsystemAssignee: KMyMoney Devel Mailing List <kmymoney-devel>
Status: RESOLVED FIXED    
Severity: normal    
Priority: NOR    
Version: git (master)   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In: 5.1.90
Sentry Crash Report:
Bug Depends on:    
Bug Blocks: 488491    

Description Ralf Habacker 2024-11-12 08:15:11 UTC
STEPS TO REPRODUCE
1.  build kmymoney from source from the git master branch
2.  run the embedded tests
3. inspect test results

OBSERVED RESULT
mymoneyxmlreader-tests fails with the following error: 

32: QWARN  : MyMoneyXmlReaderTest::testReadOnlineJobs() In the file is a onlineTask for which I could not find the plugin ('org.kmymoney.creditTransfer.sepa')
32: FAIL!  : MyMoneyXmlReaderTest::testReadOnlineJobs() Compared values are not the same
32:    Actual   (onlineJob.taskIid())                              : "org.kmymoney.onlineTask.unavailableTask"
32:    Expected (QLatin1String("org.kmymoney.creditTransfer.sepa")): "org.kmymoney.creditTransfer.sepa"
32:    Loc: [/builds/office/kmymoney/kmymoney/plugins/xml/tests/mymoneyxmlreader-test.cpp(808)]

EXPECTED RESULT
The test should not fail

SOFTWARE/OS VERSIONS
Linux: openSUSE Leap 15.5  
KDE Frameworks Version: 5.102
Qt Version: 5.15.8
Comment 1 Ralf Habacker 2024-11-12 08:24:34 UTC
Git commit e5b96fa15ec6c51e2a8bbe85970b1bd884b1a6ef by Ralf Habacker.
Committed on 12/11/2024 at 08:18.
Pushed by habacker into branch 'master'.

Fix test error in mymoneyxmlreader-tests when started from the build directory

The cause of the problem was that the plugin in question was created
in the wrong build directory by manually overwriting the settings
for the build location.
FIXED-IN:5.1.90

M  +0    -1    kmymoney/plugins/onlinetasks/sepa/CMakeLists.txt

https://invent.kde.org/office/kmymoney/-/commit/e5b96fa15ec6c51e2a8bbe85970b1bd884b1a6ef