Commit 62319c1e by Dima Bart

Rename from getter to property name: isCancelled -> cancelled

parent 91e65606
......@@ -49,11 +49,11 @@
XCTAssertTrue(operation.isReady);
[operation start];
XCTAssertTrue(operation.isExecuting);
XCTAssertTrue(operation.executing);
[operation finishExecution];
XCTAssertTrue(operation.isFinished);
XCTAssertFalse(operation.isCancelled);
XCTAssertFalse(operation.cancelled);
}
- (void)testCancelledExecutionFlow
......@@ -62,10 +62,10 @@
XCTAssertTrue(operation.isReady);
[operation start];
XCTAssertTrue(operation.isExecuting);
XCTAssertTrue(operation.executing);
[operation cancel];
XCTAssertTrue(operation.isCancelled);
XCTAssertTrue(operation.cancelled);
XCTAssertFalse(operation.isFinished);
[operation cancelExecution];
......
......@@ -66,7 +66,7 @@
- (void)finishWithCheckout:(BUYCheckout *)checkout
{
if (self.isCancelled) {
if (self.cancelled) {
return;
}
......@@ -76,7 +76,7 @@
- (void)finishWithError:(NSError *)error
{
if (self.isCancelled) {
if (self.cancelled) {
return;
}
......@@ -90,7 +90,7 @@
- (void)startExecution
{
if (self.isCancelled) {
if (self.cancelled) {
return;
}
......
......@@ -97,7 +97,7 @@ typedef void (^BUYRequestJSONCompletion)(NSDictionary *json, NSHTTPURLResponse *
- (void)startExecution
{
if (self.isCancelled) {
if (self.cancelled) {
return;
}
......@@ -126,13 +126,13 @@ typedef void (^BUYRequestJSONCompletion)(NSDictionary *json, NSHTTPURLResponse *
- (NSURLSessionDataTask *)requestUsingPollingIfNeeded:(NSURLRequest *)request completion:(BUYRequestJSONCompletion)completion
{
if (self.isCancelled) {
if (self.cancelled) {
return nil;
}
return [self request:request completion:^(NSDictionary *json, NSHTTPURLResponse *response, NSError *error) {
if (self.isCancelled) {
if (self.cancelled) {
return;
}
......@@ -145,7 +145,7 @@ typedef void (^BUYRequestJSONCompletion)(NSDictionary *json, NSHTTPURLResponse *
if (self.pollingHandler && self.pollingHandler(json, response, error)) {
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(self.pollingInterval * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
if (self.isCancelled) {
if (self.cancelled) {
return;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment