<commit_before>package main

import (
	"os/exec"
	"strings"
	"testing"
)

func execCommand(command string) string {
	cmd := exec.Command("bash", "-c", command)
	output, _ := cmd.Output()

	return strings.Trim(string(output), " \n")
}

func errToBool(err error) bool {
	if err == nil {
		return false
	}

	return true
}

func TestGitRepositoryStore_GetRepository(t *testing.T) {
	execCommand("cd fixtures/depot/project-x && rm -rf non-bare-repo-a && git clone repo-a.git non-bare-repo-a")

	var tests = []struct {
		repoPath       string
		actualRepoPath string
		error          bool<commit_msg>Print exec helper stderr to ... stderr<commit_after>package main

import (
	"os"
	"os/exec"
	"strings"
	"testing"
)

func execCommand(command string) string {
	cmd := exec.Command("bash", "-c", command)
	cmd.Stderr = os.Stderr
	output, _ := cmd.Output()

	return strings.Trim(string(output), " \n")
}

func errToBool(err error) bool {
	if err == nil {
		return false
	}

	return true
}

func TestGitRepositoryStore_GetRepository(t *testing.T) {
	execCommand("cd fixtures/depot/project-x && rm -rf non-bare-repo-a && git clone repo-a.git non-bare-repo-a")

	var tests = []struct {
		repoPath       string
		actualRepoPath string
		error          bool
{'fraction_non_alphanumeric': 0.13515687851971037, 'fraction_numerical': 0.0, 'mean_word_length': 3.54014598540146, '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': '5797846', 'n_tokens_mistral': 455, 'n_tokens_neox': 430, 'n_words': 109}