
Identifiers in Blink now largely follow the standard Chrome style conventions, with several additional rules: - web-exposed methods remain namedLikeThis() for consistency with Javascript bindings. - method names are never named_in_hacker_case() - enumerator names are kNamedLikeThis. This commit was generated by the following process. 1. Running //tools/clang/rewrite_to_chrome_style across the codebase. 2. Apply manual fixes. 3. git cl format BUG=578344 R=lukasza@chromium.org TBR=darin@chromium.org Change-Id: Ide5d397d3c6a5d973fd0a6f81dccf82561d4bb71 Reviewed-on: https://chromium-review.googlesource.com/472192 Reviewed-by: Blink Reformat <blink-reformat@chromium.org> Cr-Commit-Position: refs/heads/master@{#463139}
39 lines
1.2 KiB
C++
39 lines
1.2 KiB
C++
// Copyright (c) 2010 The Chromium Authors. All rights reserved.
|
|
// Use of this source code is governed by a BSD-style license that can be
|
|
// found in the LICENSE file.
|
|
|
|
#include <stdint.h>
|
|
|
|
#include "content/test/image_decoder_test.h"
|
|
#include "third_party/WebKit/public/web/WebImageDecoder.h"
|
|
|
|
class BMPImageDecoderTest : public ImageDecoderTest {
|
|
public:
|
|
BMPImageDecoderTest() : ImageDecoderTest("bmp") { }
|
|
|
|
protected:
|
|
blink::WebImageDecoder* CreateWebKitImageDecoder() const override {
|
|
return new blink::WebImageDecoder(blink::WebImageDecoder::kTypeBMP);
|
|
}
|
|
|
|
// The BMPImageDecoderTest tests are really slow under Valgrind.
|
|
// Thus it is split into fast and slow versions. The threshold is
|
|
// set to 10KB because the fast test can finish under Valgrind in
|
|
// less than 30 seconds.
|
|
static const int64_t kThresholdSize = 10240;
|
|
};
|
|
|
|
TEST_F(BMPImageDecoderTest, DecodingFast) {
|
|
TestDecoding(TEST_SMALLER, kThresholdSize);
|
|
}
|
|
|
|
#if defined(THREAD_SANITIZER)
|
|
// BMPImageDecoderTest.DecodingSlow always times out under ThreadSanitizer v2.
|
|
#define MAYBE_DecodingSlow DISABLED_DecodingSlow
|
|
#else
|
|
#define MAYBE_DecodingSlow DecodingSlow
|
|
#endif
|
|
TEST_F(BMPImageDecoderTest, MAYBE_DecodingSlow) {
|
|
TestDecoding(TEST_BIGGER, kThresholdSize);
|
|
}
|