<commit_before>package graph

import (
	"container/heap"
	"fmt"
	"testing"
)

func TestPriority(t *testing.T) {
	h := make(priority, 0)
	h.Add(&node{nil, "a"}, 3)
	h.Add(&node{nil, "b"}, 2)
	h.Add(&node{nil, "c"}, 4)
	heap.Init(&h)
	x := heap.Pop(&h).(*edge)
	if x.target.value != "b" {
		t.Errorf("Wrong target found: %v", x.target.value)
	}
}

func TestPopEmpty(t *testing.T) {
	h := make(priority, 0)
	h.Add(&node{nil, "a"}, 1)
	heap.Init(&h)
	for i := 0; i < 1; i++ {
		x := heap.Pop(&h).(*edge)
		fmt.Println(x.target.value)<commit_msg>Fixed unit test sillyness (printing instead of testing).<commit_after>package graph

import (
	"container/heap"
	"testing"
)

func TestPriority(t *testing.T) {
	h := make(priority, 0)
	h.Add(&node{nil, "a"}, 3)
	h.Add(&node{nil, "b"}, 2)
	h.Add(&node{nil, "c"}, 4)
	heap.Init(&h)
	x := heap.Pop(&h).(*edge)
	if x.target.value != "b" {
		t.Errorf("Wrong target found: %v", x.target.value)
	}
}

func TestPopEmpty(t *testing.T) {
	h := make(priority, 0)
	h.Add(&node{nil, "a"}, 1)
	heap.Init(&h)
	x := heap.Pop(&h).(*edge)
	if x.target.value != "a" {
		t.Errorf("Something wrong with the priority queue.")
{'fraction_non_alphanumeric': 0.23164335664335664, 'fraction_numerical': 0.012237762237762238, 'mean_word_length': 4.021929824561403, 'pattern_counts': {'":': 0, '<': 4, '<?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': '4588445', 'n_tokens_mistral': 519, 'n_tokens_neox': 498, 'n_words': 109}