Fix PackageManagerSettingsTest failures

Bug: 172654903

SparseArray.equals() does not compare array content.  Replace the call
to SparseArray.equals() in LegacyPermissionState.equals() with a loop
that verifies that the content is the same.

Test: FrameworksServicesTests:PackageManagerSettingsTests
Change-Id: I04e7d57ca877339d1594b7b41ea7acae2fc9bd88
1 file changed