func TestFrontmatterFound(t *testing.T) {
	file := "ok"
	data.AllFiles = make(map[string]*data.FileDetails)
	data.AddFile(file, file)

	err := CheckHugoFrontmatter(linereader.ByteReader(OK_TOPIC), file)

	if err != nil {
		t.Errorf("ERROR parsing: %v", err)
	}
}
func TestFrontmatterError(t *testing.T) {
	file := "missing"
	data.AllFiles = make(map[string]*data.FileDetails)
	data.AddFile(file, file)

	err := CheckHugoFrontmatter(linereader.ByteReader(MISSING_COMMENT_END_TOPIC), file)

	if err == nil {
		t.Errorf("Expected error")
	} else {
		if err.Error() != "Did not find expected close metadata comment" {
			t.Errorf("unexpected ERROR parsing: %v", err)
		}
	}
}