package helpers

import "github.com/cucumber/messages-go/v10"

// TableFields provides the header fields of the given table.
func TableFields(table *messages.PickleStepArgument_PickleTable) []string {
	result := []string{}
	for _, cell := range table.Rows[0].Cells {
		result = append(result, cell.Value)
	}
	return result
}
