|
@@ -40,7 +40,10 @@ static int64_t kAsyncTestTimeout = 5; |
|
@@ -40,7 +40,10 @@ static int64_t kAsyncTestTimeout = 5; |
40
|
|
40
|
|
41
|
NSURL *originalImageURL = [NSURL URLWithString:@"http://s3.amazonaws.com/fast-image-cache/demo-images/FICDDemoImage000.jpg"];
|
41
|
NSURL *originalImageURL = [NSURL URLWithString:@"http://s3.amazonaws.com/fast-image-cache/demo-images/FICDDemoImage000.jpg"];
|
42
|
|
42
|
|
43
|
- [[SDWebImageManager sharedManager] loadImageWithURL:originalImageURL options:SDWebImageRefreshCached progress:nil completed:^(UIImage *image, NSError *error, SDImageCacheType cacheType, BOOL finished, NSURL *imageURL) {
|
43
|
+ [[SDWebImageManager sharedManager] loadImageWithURL:originalImageURL
|
|
|
44
|
+ options:SDWebImageRefreshCached
|
|
|
45
|
+ progress:nil
|
|
|
46
|
+ completed:^(UIImage *image, NSData *data, NSError *error, SDImageCacheType cacheType, BOOL finished, NSURL *imageURL) {
|
44
|
expect(image).toNot.beNil();
|
47
|
expect(image).toNot.beNil();
|
45
|
expect(error).to.beNil();
|
48
|
expect(error).to.beNil();
|
46
|
expect(originalImageURL).to.equal(imageURL);
|
49
|
expect(originalImageURL).to.equal(imageURL);
|
|
@@ -57,7 +60,10 @@ static int64_t kAsyncTestTimeout = 5; |
|
@@ -57,7 +60,10 @@ static int64_t kAsyncTestTimeout = 5; |
57
|
|
60
|
|
58
|
NSURL *originalImageURL = [NSURL URLWithString:@"http://static2.dmcdn.net/static/video/656/177/44771656:jpeg_preview_small.png"];
|
61
|
NSURL *originalImageURL = [NSURL URLWithString:@"http://static2.dmcdn.net/static/video/656/177/44771656:jpeg_preview_small.png"];
|
59
|
|
62
|
|
60
|
- [[SDWebImageManager sharedManager] loadImageWithURL:originalImageURL options:SDWebImageRefreshCached progress:nil completed:^(UIImage *image, NSError *error, SDImageCacheType cacheType, BOOL finished, NSURL *imageURL) {
|
63
|
+ [[SDWebImageManager sharedManager] loadImageWithURL:originalImageURL
|
|
|
64
|
+ options:SDWebImageRefreshCached
|
|
|
65
|
+ progress:nil
|
|
|
66
|
+ completed:^(UIImage *image, NSData *data, NSError *error, SDImageCacheType cacheType, BOOL finished, NSURL *imageURL) {
|
61
|
expect(image).to.beNil();
|
67
|
expect(image).to.beNil();
|
62
|
expect(error).toNot.beNil();
|
68
|
expect(error).toNot.beNil();
|
63
|
expect(originalImageURL).to.equal(imageURL);
|
69
|
expect(originalImageURL).to.equal(imageURL);
|