You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: commit_filter_test.go
    path of file: ./repos/grv/cmd/grv
    
    the code of the file until where you have to start completion: package main

import (
	"os"
	"reflect"
	"testing"

	git "gopkg.in/libgit2/git2go.v27"
)

func TestCommitFieldExistence(t *testing.T) {
	var fieldExistsTests = []struct {
		fieldName      string
		expectedExists bool
	}{
		{
			fieldName:      "authorname",
			expectedExists: true,
		},
		{
			fieldName:      "invalidfield",
			expectedExists: false,
		},
		{
			fieldName:      "authordate",
			expectedExists: true,
		},
		{
			fieldName:      "comittername",
			expectedExists: false,
		},
	}

	commitFieldDescriptor := &CommitFieldDescriptor{}

	for _, fieldExistsTest := range fieldExistsTests {
		fieldName := fieldExistsTest.fieldName
    
func TestCommitFieldTypes(t *testing.T) {
	var commitFieldTypeTests = []struct {
		fieldName         string
		expectedFieldType FieldType
	}{
		{
			fieldName:         "authorname",
			expectedFieldType: FtString,
		},
		{
			fieldName:         "authoremail",
			expectedFieldType: FtString,
		},
		{
			fieldName:         "authordate",
			expectedFieldType: FtDate,
		},
		{
			fieldName:         "committername",
			expectedFieldType: FtString,
		},
		{
			fieldName:         "committeremail",
			expectedFieldType: FtString,
		},
		{
			fieldName:         "committerdate",
			expectedFieldType: FtDate,
		},
		{
			fieldName:         "id",
			expectedFieldType: FtString,
		},
		{
			fieldName:         "summary",
			expectedFieldType: FtString,
		},
		{
			fieldName:         "parentcount",
			expectedFieldType: FtNumber,
		},
	}

	commitFieldDescriptor := &CommitFieldDescriptor{}

	for _, commitFieldTypeTest := range commitFieldTypeTests {
		fieldName := commitFieldTypeTest.fieldName
		expectedFieldType := commitFieldTypeTest.expectedFieldType

		actualFieldType, fieldExists := commitFieldDescriptor.FieldType(fieldName)

		if !fieldExists {
			t.Errorf("Expected field %v to exist", fieldName)
		} else if expectedFieldType != actualFieldType {
			t.Errorf("Field type does not match expected value for field %v. Expected: %v, Actual: %v", fieldName, expectedFieldType, actualFieldType)
		}
	}
}