This file explains the purpose of this directory and how to set everything up
to run the related unit test to verify the icon visibility algorithm is
working reasonably well.
The unit test is in src/extensions/common/image_util_unittest.cc and is
disabled, so it doesn't run under normal testing:
TEST(ImageUtilTest, DISABLED_AnalyzeAllDownloadedIcons)
There will be two sets of input data: a file that contains the URLs for the
top 5000 extension icons in web store and the icon image files. These URLs
are generated by a query against the underlying web store database. The query
is available in PLX here:
https://plx.corp.google.com/scripts2/script_5c._4ae232_0000_2abb_8c52_001a11c10446
Once the query has executed, download the results to a file called
"source_urls.txt." Edit this file to remove the first line, which is the column
name for the CSV format.
Create a directory called "pngs" then change to that directory and use wget
to download all of the icons:
mkdir pngs
cd pngs
wget -i ../source_urls.txt
This will take a while, but once it's completed, you should see all 5000 files
in the directory.
You can now run the unit test, which will create two output artifacts: A file
called "invisible_source_urls.txt" which contains the URLs of the icons that
were considered not sufficiently visible, along with an output directory
called "invisible_pngs" that contains the rendered icons.
You can then look at the rendered icons to understand what the algorithm does
and correlate them back to the original icons. If any icons look like they
should have passed but didn't, it's helpful to create a sample extension using
the _original_ icon for the browser action, so you can see the icon in the
toolbar.