<commit_before>//
//  LocationTests.swift
//  Incidents
//
//  © 2015 Burning Man and its contributors. All rights reserved.
//  See the file COPYRIGHT.md for terms.
//

import XCTest



class LocationDescriptionTests: XCTestCase {

    let address = RodGarettAddress(
        concentric      : ConcentricStreet.C,
        radialHour      : 8,
        radialMinute    : 45,
        textDescription : "Red and yellow flags, dome"
    )

    
    func test_description_full() {
        let location = Location(
            name: "Camp Equilibrium",
            address: address
        )

        XCTAssertEqual(
            location.description,
            "Camp Equilibrium (8:45@C, Red and yellow flags, dome)"
        )
    }


    func test_description_name() {
        let location = Location(name: "Camp Equilibrium")

        XCTAssertEqual(
            location.description,
            "Camp Equilibrium"
        )
    }


    func test_description_address() {
        let location = Location(address: address)

        XCTAssertEqual(
            location.description,
            "(8:45@C, Red and yellow flags, dome)"
        )
    }


    func test_description_same() {
        let location = Location(
            name: "The Man",
            address: TextOnlyAddress(textDescription: "The Man")
        )

        XCTAssertEqual(
            location.description,
            "The Man"
        )
    }

}



class LocationNillishTests: XCTestCase {

    func test_nilAttributes() {
        XCTAssertTrue(Location().isNillish())
    }<commit_msg>Don't hard code street names in expected description strings.<commit_after>//
//  LocationTests.swift
//  Incidents
//
//  © 2015 <NAME> and its contributors. All rights reserved.
//  See the file COPYRIGHT.md for terms.
//

import XCTest



class LocationDescriptionTests: XCTestCase {

    let address = RodGarettAddress(
        concentric      : ConcentricStreet.C,
        radialHour      : 8,
        radialMinute    : 45,
        textDescription : "Red and yellow flags, dome"
    )

    
    func test_description_full() {
        let location = Location(
            name: "Camp Equilibrium",
            address: address
        )

        XCTAssertEqual(
            location.description,
            "Camp Equilibrium (8:45@\(ConcentricStreet.C), Red and yellow flags, dome)"
        )
    }


    func test_description_name() {
        let location = Location(name: "Camp Equilibrium")

        XCTAssertEqual(
            location.description,
            "Camp Equilibrium"
        )
    }


    func test_description_address() {
        let location = Location(address: address)

        XCTAssertEqual(
            location.description,
            "(8:45@\(ConcentricStreet.C), Red and yellow flags, dome)"
        )
    }


    func test_description_same() {
        let location = Location(
            name: "The Man",
            address: TextOnlyAddress(textDescription: "The Man")
        )

        XCTAssertEqual(
            location.description,
            "The Man"
        )
    }

}



class LocationNillishTests: XCTestCase {

    func test_nilAttributes() {
        XCTAssertTrue(Location().isNillish())
    }
{'fraction_non_alphanumeric': 0.08866687480487044, 'fraction_numerical': 0.008117389946924758, 'mean_word_length': 1.8683974932855865, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 4, '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': '3203066', 'n_tokens_mistral': 935, 'n_tokens_neox': 862, 'n_words': 219}