Fix run_decoding_tests on xoom.
Builder Test-Android-Xoom-Tegra2-Arm7-Debug fails run_decoding_tests due to a couple of images. Add a way in skimage to ignore failures if an image is expected to fail. Add an expectations file for xoom that includes ignore-failure for the two files which are failing. I have created https://code.google.com/p/skia/issues/detail?id=1382 to track the fact that these images fail to decode, despite the bot showing green. R=borenet@google.com Review URL: https://codereview.chromium.org/18023008 git-svn-id: http://skia.googlecode.com/svn/trunk@9797 2bbb7eff-a529-9590-31e7-b0007b416f81
This commit is contained in:
parent
6e49c345b1
commit
bc91e8b7d7
142
expectations/skimage/base-android-xoom.json
Normal file
142
expectations/skimage/base-android-xoom.json
Normal file
@ -0,0 +1,142 @@
|
||||
{
|
||||
"actual-results" : {
|
||||
"failed" : null,
|
||||
"failure-ignored" : null,
|
||||
"no-comparison" : null,
|
||||
"succeeded" : null
|
||||
},
|
||||
"expected-results" : {
|
||||
"01_original.jpg" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 6357612266670593419 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"02_empty_filter.JPG" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 13796732312180268210 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"03_none_filter.JPG" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 6388620656649963843 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"Lower_Left.jpg" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 3518857344143029942 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"Lower_Right.jpg" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 4640356172221432257 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"PANO_20121023_214540.jpg" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 15493791864227637231 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"Upper_Left.jpg" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 7518208176958373090 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"Upper_Right.jpg" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 10122895588403815825 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"desk_yahoonews_0.jpg" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 15513164475782874663 ]
|
||||
],
|
||||
"ignore-failure" : true
|
||||
},
|
||||
"kokteylogo.png" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 168800254427225818 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"kokteylogo.png_[26,0,57,17]" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 3464562511481035166 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"kokteylogo.png_[26,4,45,5]" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 11569166933584178547 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"kokteylogo.png_[27,8,36,9]" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 14506072359562678944 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"kokteylogo.png_[38,4,53,17]" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 4980413816844234835 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"kokteylogo.png_[69,4,71,17]" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 15430159324265259188 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"photo.jpg.png" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 76400998740744557 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"photo.jpg.png_[134,45,259,424]" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 10088437173476931079 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"photo.jpg.png_[2,132,367,377]" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 6938435300895122197 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"photo.jpg.png_[231,348,282,433]" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 13214547049530016247 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"photo.jpg.png_[238,80,267,373]" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 7766349704315583680 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"photo.jpg.png_[306,233,351,308]" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 11244796826105366429 ]
|
||||
],
|
||||
"ignore-failure" : false
|
||||
},
|
||||
"tabl_mozilla_0.jpg" : {
|
||||
"allowed-digests" : [
|
||||
[ "bitmap-64bitMD5", 13794277939360474741 ]
|
||||
],
|
||||
"ignore-failure" : true
|
||||
}
|
||||
}
|
||||
}
|
@ -163,6 +163,18 @@ static void write_expectations(const SkBitmap& bitmap, const char* filename) {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Return true if this filename is a known failure, and therefore a failure
|
||||
* to decode should be ignored.
|
||||
*/
|
||||
static bool expect_to_fail(const char* filename) {
|
||||
if (NULL == gJsonExpectations.get()) {
|
||||
return false;
|
||||
}
|
||||
skiagm::Expectations jsExpectations = gJsonExpectations->get(filename);
|
||||
return jsExpectations.ignoreFailure();
|
||||
}
|
||||
|
||||
/**
|
||||
* Compare against an expectation for this filename, if there is one.
|
||||
* @param bitmap SkBitmap to compare to the expected value.
|
||||
@ -299,16 +311,22 @@ static void decodeFileAndWrite(const char srcPath[], const SkString* writePath)
|
||||
SkAutoTDelete<SkImageDecoder> ad(codec);
|
||||
|
||||
stream.rewind();
|
||||
if (!codec->decode(&stream, &bitmap, SkBitmap::kARGB_8888_Config,
|
||||
SkImageDecoder::kDecodePixels_Mode)) {
|
||||
gDecodeFailures.push_back().set(srcPath);
|
||||
return;
|
||||
}
|
||||
|
||||
// Create a string representing just the filename itself, for use in json expectations.
|
||||
SkString basename = SkOSPath::SkBasename(srcPath);
|
||||
const char* filename = basename.c_str();
|
||||
|
||||
if (!codec->decode(&stream, &bitmap, SkBitmap::kARGB_8888_Config,
|
||||
SkImageDecoder::kDecodePixels_Mode)) {
|
||||
if (expect_to_fail(filename)) {
|
||||
gSuccessfulDecodes.push_back().appendf(
|
||||
"failed to decode %s, which is a known failure.", srcPath);
|
||||
} else {
|
||||
gDecodeFailures.push_back().set(srcPath);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
if (compare_to_expectations_if_necessary(bitmap, filename, &gDecodeFailures)) {
|
||||
gSuccessfulDecodes.push_back().printf("%s [%d %d]", srcPath, bitmap.width(),
|
||||
bitmap.height());
|
||||
|
Loading…
Reference in New Issue
Block a user