<commit_before>
// --- stubs ---

class URL
{
	init?(string: String) {}
	init?(string: String, relativeTo: URL?) {}
}

// --- tests ---

func test1(passwd : String, encrypted_passwd : String, account_no : String, credit_card_no : String) {
	let a = URL(string: "http://example.com/login?p=" + passwd); // BAD
	let b = URL(string: "http://example.com/login?p=" + encrypted_passwd); // GOOD (not sensitive)
	let c = URL(string: "http://example.com/login?ac=" + account_no); // BAD [NOT DETECTED]
	let d = URL(string: "http://example.com/login?cc=" + credit_card_no); // BAD

	let base = URL(string: "http://example.com/"); // GOOD (not sensitive)
	let e = URL(string: "abc", relativeTo: base); // GOOD (not sensitive)
	let f = URL(string: passwd, relativeTo: base); // BAD
	let g = URL(string: "abc", relativeTo: f); // BAD [NOT DETECTED]
}<commit_msg>Swift: Update the test.<commit_after>
// --- stubs ---

class URL
{
	init?(string: String) {}
	init?(string: String, relativeTo: URL?) {}
}

// --- tests ---

func test1(passwd : String, encrypted_passwd : String, account_no : String, credit_card_no : String) {
	let a = URL(string: "http://example.com/login?p=" + passwd); // BAD
	let b = URL(string: "http://example.com/login?p=" + encrypted_passwd); // GOOD (not sensitive)
	let c = URL(string: "http://example.com/login?ac=" + account_no); // BAD [NOT DETECTED]
	let d = URL(string: "http://example.com/login?cc=" + credit_card_no); // BAD

	let base = URL(string: "http://example.com/"); // GOOD (not sensitive)
	let e = URL(string: "abc", relativeTo: base); // GOOD (not sensitive)
	let f = URL(string: passwd, relativeTo: base); // BAD
	let g = URL(string: "abc", relativeTo: f); // BAD (reported on line above)
}
{'fraction_non_alphanumeric': 0.19883720930232557, 'fraction_numerical': 0.0011627906976744186, 'mean_word_length': 3.6639566395663956, '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': '7317767', 'n_tokens_mistral': 624, 'n_tokens_neox': 609, 'n_words': 165}