Fix the test case testFLAnimatedImageViewSetImageWithURL because of remote resource is not available
This commit is contained in:
parent
205e376388
commit
50b6a09a9b
|
@ -126,7 +126,7 @@ static void * SDCategoriesTestsContext = &SDCategoriesTestsContext;
|
|||
XCTestExpectation *expectation = [self expectationWithDescription:@"FLAnimatedImageView setImageWithURL"];
|
||||
|
||||
FLAnimatedImageView *imageView = [[FLAnimatedImageView alloc] init];
|
||||
NSURL *originalImageURL = [NSURL URLWithString:@"https://www.interntheory.com/img/loading-small.gif"];
|
||||
NSURL *originalImageURL = [NSURL URLWithString:kTestGIFURL];
|
||||
|
||||
[imageView sd_setImageWithURL:originalImageURL
|
||||
completed:^(UIImage * _Nullable image, NSError * _Nullable error, SDImageCacheType cacheType, NSURL * _Nullable imageURL) {
|
||||
|
|
|
@ -17,6 +17,8 @@ FOUNDATION_EXPORT const int64_t kAsyncTestTimeout;
|
|||
FOUNDATION_EXPORT const int64_t kMinDelayNanosecond;
|
||||
FOUNDATION_EXPORT NSString * _Nonnull const kTestJpegURL;
|
||||
FOUNDATION_EXPORT NSString * _Nonnull const kTestPNGURL;
|
||||
FOUNDATION_EXPORT NSString * _Nonnull const kTestGIFURL;
|
||||
FOUNDATION_EXPORT NSString * _Nonnull const kTestWebPURL;
|
||||
|
||||
@interface SDTestCase : XCTestCase
|
||||
|
||||
|
|
|
@ -13,6 +13,8 @@ const int64_t kAsyncTestTimeout = 5;
|
|||
const int64_t kMinDelayNanosecond = NSEC_PER_MSEC * 100; // 0.1s
|
||||
NSString *const kTestJpegURL = @"http://via.placeholder.com/50x50.jpg";
|
||||
NSString *const kTestPNGURL = @"http://via.placeholder.com/50x50.png";
|
||||
NSString *const kTestGIFURL = @"https://media.giphy.com/media/UEsrLdv7ugRTq/giphy.gif";
|
||||
NSString *const kTestWebPURL = @"http://littlesvr.ca/apng/images/SteamEngine.webp";
|
||||
|
||||
@implementation SDTestCase
|
||||
|
||||
|
|
Loading…
Reference in New Issue