<commit_before>//
//  Alamofire_SwiftyJSONTests.swift
//  Alamofire-SwiftyJSONTests
//
//  Created by <NAME> on 14-9-23.
//  Copyright (c) 2014年 SwiftJSON. All rights reserved.
//

import UIKit
import XCTest
import Alamofire
import SwiftyJSON
import AlamofireSwiftyJSON

class Alamofire_SwiftyJSONTests: XCTestCase {
    
    func testJSONResponse() {
        let URL = "http://httpbin.org/get"
        let expectation = expectationWithDescription("\(URL)")
        
        Alamofire.request(.GET, URL, parameters: ["foo": "bar"])
            .responseSwiftyJSON { (request, response, responseJSON, error) in
                expectation.fulfill()
                XCTAssertNotNil(request, "request should not be nil")
                XCTAssertNotNil(response, "response should not be nil")
                XCTAssertNil(error, "error should be nil")
                XCTAssertEqual(responseJSON["args"], SwiftyJSON.JSON(["foo": "bar"] as NSDictionary), "args should be equal")
        }
        
        waitForExpectationsWithTimeout(10) { (error) in
            XCTAssertNil(error, "\(error)")
        }
    }
    
}<commit_msg>fix ambiguous method<commit_after>//
//  Alamofire_SwiftyJSONTests.swift
//  Alamofire-SwiftyJSONTests
//
//  Created by <NAME> on 14-9-23.
//  Copyright (c) 2014年 SwiftJSON. All rights reserved.
//

import UIKit
import XCTest
import Alamofire
import SwiftyJSON
import AlamofireSwiftyJSON

class Alamofire_SwiftyJSONTests: XCTestCase {

    func testJSONResponse() {
        let URL = "http://httpbin.org/get"
        let expectation = expectationWithDescription("\(URL)")

        Alamofire.request(.GET, URL, parameters: ["foo": "bar"])
            .responseSwiftyJSON( { (request, response, responseJSON, error) in
                expectation.fulfill()
                XCTAssertNotNil(request, "request should not be nil")
                XCTAssertNotNil(response, "response should not be nil")
                XCTAssertNil(error, "error should be nil")
                XCTAssertEqual(responseJSON["args"], SwiftyJSON.JSON(["foo": "bar"] as NSDictionary), "args should be equal")
        })

        waitForExpectationsWithTimeout(10) { (error) in
            XCTAssertNil(error, "\(error)")
        }
    }

}
{'fraction_non_alphanumeric': 0.11244979919678715, 'fraction_numerical': 0.009817045961624275, 'mean_word_length': 2.621970920840065, 'pattern_counts': {'":': 4, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '113189', 'n_tokens_mistral': 715, 'n_tokens_neox': 679, 'n_words': 160}