<commit_before>//
//  PerformanceTests.swift
//  Siesta
//
//  Created by Paul on 2016/9/27.
//  Copyright © 2016 Bust Out Solutions. All rights reserved.
//

import Foundation
import XCTest
import Siesta

class SiestaPerformanceTests: XCTestCase
    {
    var service: Service!
    var networkStub: NetworkStub!

    override func setUp()
        {
        networkStub = NetworkStub()
        service = Service(baseURL: "http://test.ing", networking: networkStub)
        }

    func testGetExistingResourcesByURL()
        {<commit_msg>Trigger memory flush in tearDown for more consistent perf tests<commit_after>//
//  PerformanceTests.swift
//  Siesta
//
//  Created by Paul on 2016/9/27.
//  Copyright © 2016 Bust Out Solutions. All rights reserved.
//

import Foundation
import XCTest
import Siesta

class SiestaPerformanceTests: XCTestCase
    {
    var service: Service!
    var networkStub: NetworkStub!

    override func setUp()
        {
        networkStub = NetworkStub()
        service = Service(baseURL: "http://test.ing", networking: networkStub)
        }

    override func tearDown()
        {
        NotificationCenter.default
            .post(
                name: NSNotification.Name("Siesta.MemoryWarningNotification"),
                object: nil)
        }

    func testGetExistingResourcesByURL()
        {
{'fraction_non_alphanumeric': 0.09043348281016443, 'fraction_numerical': 0.016442451420029897, 'mean_word_length': 2.433333333333333, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '5740927', 'n_tokens_mistral': 393, 'n_tokens_neox': 375, 'n_words': 106}