summaryrefslogtreecommitdiffstats
path: root/vendor/github.com/pseudomuto/protoc-gen-doc/bench_test.go
blob: 3bc066e148ab0db0c0173651f5e1ae39f3c951c5 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
package gendoc_test

import (
	"testing"

	. "github.com/pseudomuto/protoc-gen-doc"
	"github.com/pseudomuto/protokit/utils"
)

func BenchmarkParseCodeRequest(b *testing.B) {
	set, _ := utils.LoadDescriptorSet("fixtures", "fileset.pb")
	req := utils.CreateGenRequest(set, "Booking.proto", "Vehicle.proto")
	plugin := new(Plugin)

	for i := 0; i < b.N; i++ {
		plugin.Generate(req)
	}
}