def assert_scanned(self, specs_strings, expected, address_mapper=None):
    address_mapper = address_mapper or self.address_mapper

    def sort(addresses):
      return sorted(addresses, key=lambda address: address.spec)

    specs = [self._spec_parser.parse_spec(s) for s in specs_strings]

    self.assertEqual(sort(Address.parse(addr) for addr in expected),
                     sort(address_mapper.scan_specs(specs)))
Parse and scan the given specs.
dataset/ETHPy150Open pantsbuild/pants/tests/python/pants_test/build_graph/test_build_file_address_mapper.py/BuildFileAddressMapperScanTest.assert_scanned