Erweiterung von Kurt Jungs gopdf, das leider nicht weiterentwickelt wird
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

26 lines
616 B

package main
import (
func TestMakefont(t *testing.T) {
var out []byte
var err error
const expect = "Font definition file successfully generated"
// Make sure makefont utility has been built before generating font definition file
err = exec.Command("go", "build").Run()
if err != nil {
out, err = exec.Command("./makefont", "--dst=../font", "--embed",
"--enc=../font/", "../font/calligra.ttf").CombinedOutput()
if err != nil {
if !strings.Contains(string(out), expect) {
t.Fatalf("Unexpected output from makefont")