Fix dupe handling in requestAddLauncherToActivities; improve unit test

Authored by hein on Feb 2 2018, 7:31 PM.

Description

Fix dupe handling in requestAddLauncherToActivities; improve unit test

Summary:
The business logic was using the resolved URL in lookups in
internal data structures, instead of the internal key it
previously established equivalence to. This could lead to
junk in internal maps and unnecessarily emitted model changes.

This also improves the unit test not to require apps to be
installed, fixing the CI failure over missing Dolphin.

Reviewers: Plasma, kossebau

Subscribers: plasma-devel

Tags: Plasma

Differential Revision: https://phabricator.kde.org/D10253