title: NSMutableURLRequest setHTTPShouldHandleCookies
body: <p>I am working with xcode 5.1.1 for Logic unit testing for my iOS project</p>
  
  <p>For the below code, the <code>NSLog</code> output is "Handles cookies NO" both the times:</p>
  
  <pre><code>NSMutableURLRequest *newReq = [[NSMutableURLRequest alloc] init];
  NSLog(@"Handles cookies %@", [newReq HTTPShouldHandleCookies]? @"YES":@"NO");
  [newReq setHTTPShouldHandleCookies:YES];
  NSLog(@"Handles cookies %@", [newReq HTTPShouldHandleCookies]? @"YES":@"NO");
  </code></pre>
  
  <p>Output:</p>
  
  <pre><code>2014-05-25 19:41:03.045 xctest[2097:303] Handles cookies NO
  2014-05-25 19:41:05.983 xctest[2097:303] Handles cookies NO
  </code></pre>
  
  <p>What am I doing wrong. My test is failing due to this value not being set properly. I am quite sure the same test was passing last time around, and so <code>setHTTPShouldHandleCookie</code> would actually set the value to YES. Am I missing something here?</p>