D7930: Kdevelop CMake plugin : use canonical paths to build.dir
noreply at phabricator.kde.org
Thu Oct 19 12:00:50 UTC 2017
mwolff requested changes to this revision.
mwolff added a comment.
This revision now requires changes to proceed.
No, it should not just be a test around `QFileInfo::canonicalFilePath`, that is done already in Qt upstream for us. What I want is test(s) for the CMakeManager code you are changing. I.e. take `CMakeManager::buildDirectory` as an example. Extend the `test_cmakemanager` (i.e. add another test method there). Then play with symlink structure in a `QTemporaryDir` to replicate your erroneous setup. Finally call `CMakeManager::buildDirectory` and ensure it returns "the right thing". Similarly you can call the cmakeutils functions and check their return values for sanity.
This test should fail before you apply this patch, and then pass with this patch.
> + */
> + KDEVCMAKECOMMON_EXPORT KDevelop::Path currentCanonicalBuildDir( KDevelop::IProject* project, int builddir = -1 );
When should this function be used instead of the above? Shouldn't the above always return the canonical version?
> + */
> + KDEVCMAKECOMMON_EXPORT QStringList allCanonicalBuildDirs(KDevelop::IProject* project);
same as above
To: rjvbb, #kdevelop, apol, mwolff
Cc: flherne, mwolff, apol, kdevelop-devel, geetamc, Pilzschaf, akshaydeo, surgenight, arrowdodger
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the KDevelop-devel