<commit_before>package httpimg_test

import (
	"fmt"
	"github.com/jung-kurt/gofpdf"
	"github.com/jung-kurt/gofpdf/contrib/httpimg"
	"path/filepath"
)

const (
	cnGofpdfDir  = "./"
	cnExampleDir = cnGofpdfDir + "/pdf"
)

func exampleFilename(baseStr string) string {
	return filepath.Join(cnExampleDir, baseStr+".pdf")
}

func summary(err error, fileStr string) {<commit_msg>Httpimg: cleanup pdf path on with tests.<commit_after>package httpimg_test

import (
	"fmt"
	"github.com/jung-kurt/gofpdf"
	"github.com/jung-kurt/gofpdf/contrib/httpimg"
	"os"
	"path/filepath"
)

const (
	cnGofpdfDir  = "./"
	cnExampleDir = cnGofpdfDir + "/pdf"
)

func init() {
	cleanup()
}

func cleanup() {
	filepath.Walk(cnExampleDir,
		func(path string, info os.FileInfo, err error) (reterr error) {
			if path[len(path)-4:] == ".pdf" {
				os.Remove(path)
			}
			return
		})
}

func exampleFilename(baseStr string) string {
	return filepath.Join(cnExampleDir, baseStr+".pdf")
}

func summary(err error, fileStr string) {
{'fraction_non_alphanumeric': 0.14685314685314685, 'fraction_numerical': 0.000999000999000999, 'mean_word_length': 4.329787234042553, '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': '1983614', 'n_tokens_mistral': 411, 'n_tokens_neox': 398, 'n_words': 74}