Testing that actual = expected, not just actual ⊆  expected.
Testing that actual = expected, not just actual ⊆  expected.

MAIN PROBLEM - EQUALITY VS SUBSET-OF CHECKING
=============================================

Before this CL verification done by SavebleResourcesTest::CheckResources
is terribly incomplete - the test code only checks that "actual" is a
*subset* of "expected", when it should be checking that "actual" is
*equal* to "expected":

    // Check all links of sub-resource
    for (const auto& resource : resources_list) {
      ASSERT_TRUE(expected_resources_set.count(resource) != 0);
    }

    The code above is a refactoring from my CL, but the "subset"
    checking comes from a really old CL :-) - from the initial commit:
    https://chromium.googlesource.com/chromium/src/+blame/f5b16fed/webkit/glue/dom_operations_unittest.cc#86

This is wrong - for example the test will pass if the actual code always
returns an empty result (because an empty set is a subset of any other
set).

MAIN FIX
========

Container equality testing can be nicely done through gmock container
matchers (this even takes care of allowing for different ordering of
elements).

After the fix, it is obvious that frame urls should not be present in the
"expected" set (another confusion in the test code was using the same
"expected" set for verifying |resources_list| and older |frames_list|
(this is most obvious when looking at the verification code in an older
revision - i.e. see crrev.com/14304004/patch/86003/12032).  This is the
reason for removing |expected_frame_links| from the tests (they should
have been removed previously, in crrev.com/1308113008).

In addition to fixing equality-vs-subset-of checking, matchers also
enabled more concise code (and better error messages when test
assertions fail).

OTHER CHANGES
=============

I've also added an independent verification that the returned vectors
are of the same size (because items from a given index are supposed
to refer to the same subresources across all 3 vectors: resources_list,
referrer_urls_list, referrer_policies_list).

BUG=

Review URL: https://codereview.chromium.org/1419863002

Cr-Commit-Position: 972c6d2dc6dd5efdad1377c0d224e03eb8f276f7@{#355397}

axinging/chromium-crosswalk,axinging/chromium-crosswalk,axinging/chromium-crosswalk,axinging/chromium-crosswalk,axinging/chromium-crosswalk,axinging/chromium-crosswalk,axinging/chromium-crosswalk,axinging/chromium-crosswalk,axinging/chromium-crosswalk,axinging/chromium-crosswalk,axinging/chromium-crosswalk