• Home
  • Raw
  • Download

Lines Matching +full:- +full:- +full:workdir

19 // Set --regenerate to regenerate the golden files.
23 // tests and instead act as protoc-gen-go. This allows the test binary to
33 workdir, err := ioutil.TempDir("", "proto-test")
37 defer os.RemoveAll(workdir)
59 // Compile each package, using this binary as protoc-gen-go.
61 args := []string{"-Itestdata", "--go_out=plugins=grpc,paths=source_relative:" + workdir}
67 filepath.Walk(workdir, func(genPath string, info os.FileInfo, _ error) error {
74 relPath, err := filepath.Rel(workdir, genPath)
76 t.Errorf("filepath.Rel(%q, %q): %v", workdir, genPath, err)
80 t.Errorf("generated file %q is not relative to %q", genPath, workdir)
90 // If --regenerate set, just rewrite the golden files.
110 cmd := exec.Command("diff", "-u", goldenPath, genPath)
225 workdir, err := ioutil.TempDir("", "proto-test")
229 defer os.RemoveAll(workdir)
232 if err := os.MkdirAll(filepath.Join(workdir, dir), 0777); err != nil {
237 …if err := ioutil.WriteFile(filepath.Join(workdir, "alpha", "a.proto"), []byte(aProto), 0666); err …
241 …if err := ioutil.WriteFile(filepath.Join(workdir, "beta", "b.proto"), []byte(bProto), 0666); err !…
246 "-I" + workdir,
247 "--go_out=" + test.parameters + ":" + filepath.Join(workdir, "out"),
248 filepath.Join(workdir, "alpha", "a.proto"),
251 "-I" + workdir,
252 "--go_out=" + test.parameters + ":" + filepath.Join(workdir, "out"),
253 filepath.Join(workdir, "beta", "b.proto"),
258 outdir := filepath.Join(workdir, "out")
339 cmd := exec.Command("protoc", "--plugin=protoc-gen-go="+os.Args[0])