-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
15 changed files
with
217 additions
and
59 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -27,6 +27,7 @@ jobs: | |
- name: Generate | ||
run: | | ||
make clean | ||
make format | ||
make generate | ||
make generate-check | ||
- name: Test | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,24 @@ | ||
syntax = "proto3"; | ||
package gofakeit.test; | ||
option go_package = "github.com/rodaine/protogofakeit/gen/gofakeit/test"; | ||
|
||
import "gofakeit/gofakeit.proto"; | ||
|
||
option go_package = "github.com/rodaine/protogofakeit/gen/gofakeit/test"; | ||
|
||
message SelfRecursive { | ||
string foo = 1 [(gofakeit.generate).tag = "{phone}"]; | ||
SelfRecursive recurse = 2; | ||
} | ||
|
||
message PairRecursive { | ||
message A { B b = 1; } | ||
message B { A a = 2; } | ||
message A { | ||
B b = 1; | ||
} | ||
message B { | ||
A a = 2; | ||
} | ||
} | ||
|
||
message MessageSkipped { | ||
MessageSkipped skipped = 1 [(gofakeit.generate).skip = true]; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,28 @@ | ||
syntax = "proto3"; | ||
package gofakeit.test; | ||
option go_package = "github.com/rodaine/protogofakeit/gen/gofakeit/test"; | ||
|
||
import "gofakeit/gofakeit.proto"; | ||
|
||
option go_package = "github.com/rodaine/protogofakeit/gen/gofakeit/test"; | ||
|
||
enum OneOfEnum { | ||
ONE_OF_ENUM_UNSPECIFIED = 0; | ||
ONE_OF_ENUM_ONE = 1; | ||
ONE_OF_ENUM_TWO = 2; | ||
} | ||
|
||
message OneOf{ | ||
message OneOf { | ||
oneof fields { | ||
string scalar = 1; | ||
OneOfEnum enum = 2; | ||
OneOf message = 3; | ||
} | ||
} | ||
} | ||
|
||
// see https://github.com/rodaine/protogofakeit/issues/5 | ||
message OneOfMessages { | ||
oneof kind { | ||
OneOfMessages foo = 1; | ||
OneOfMessages bar = 2; | ||
} | ||
} |
Oops, something went wrong.