<commit_before>#!/usr/bin/env roundup

describe "git-prompt"

before() {
	PATH="$PATH:$(pwd)/../src"
	tmp_dir="$(mktemp -d 2>/dev/null || mktemp -d -t 'git-prompt')"
	cd "$tmp_dir"
}

after() {
	rm -rf $tmp_dir
}

init_git_repo() {
	git init --bare repo.git
	git clone ./repo.git
	cd repo
	PATH="$PATH:$(pwd)/../../src"
}

it_displays_nothing_in_empty_dir() {
	output="$(git-prompt.sh 2>&1)"
	test "$output" "=" ""
}

it_displays_nothing_in_empty_dir_containing_git_dir() {
	mkdir .git
	output="$(git-prompt.sh 2>&1)"
	test "$output" "=" ""
}

it_displays_branch_name() {
	init_git_repo
	output="$(git-prompt.sh 2>&1)"
	test "$output" "=" "master"
	git checkout -b mybranch
	output="$(git-prompt.sh 2>&1)"
	test "$output" "=" "mybranch"<commit_msg>Removed unnecessary PATH<commit_after>#!/usr/bin/env roundup

describe "git-prompt"

before() {
	PATH="$PATH:$(pwd)/../src"
	tmp_dir="$(mktemp -d 2>/dev/null || mktemp -d -t 'git-prompt')"
	cd "$tmp_dir"
}

after() {
	rm -rf $tmp_dir
}

init_git_repo() {
	git init --bare repo.git
	git clone ./repo.git
	cd repo
}

it_displays_nothing_in_empty_dir() {
	output="$(git-prompt.sh 2>&1)"
	test "$output" "=" ""
}

it_displays_nothing_in_empty_dir_containing_git_dir() {
	mkdir .git
	output="$(git-prompt.sh 2>&1)"
	test "$output" "=" ""
}

it_displays_branch_name() {
	init_git_repo
	output="$(git-prompt.sh 2>&1)"
	test "$output" "=" "master"
	git checkout -b mybranch
	output="$(git-prompt.sh 2>&1)"
	test "$output" "=" "mybranch"
{'fraction_non_alphanumeric': 0.21070460704607047, 'fraction_numerical': 0.012195121951219513, 'mean_word_length': 4.430147058823529, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 13, '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': '629633', 'n_tokens_mistral': 668, 'n_tokens_neox': 608, 'n_words': 116}