[ARIES-1144] Shared dependencies are uninstalled while still referenced.

New test.

Fix minor issue in existing tests regarding asserting bundle states.

When computing a subsystem's dependencies, the provider of each wire returned by the resolver will be inspected in addition
to the resources that were resolved in order to avoid omitting resources that were already resolved.

git-svn-id: https://svn.apache.org/repos/asf/aries/trunk@1556354 13f79535-47bb-0310-9956-ffa450edef68