-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add a simple test to make sure RPC Services are ignored (#2)
- Loading branch information
Showing
2 changed files
with
28 additions
and
0 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 |
---|---|---|
@@ -0,0 +1,13 @@ | ||
syntax = "proto3"; | ||
package example; | ||
|
||
message Example { | ||
string foo = 1; | ||
string bar = 2; | ||
string baz = 3; | ||
} | ||
|
||
// Make sure that services are ignored. | ||
service ExampleService { | ||
rpc DoExample(Example) returns (Example); | ||
} |
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 |
---|---|---|
@@ -0,0 +1,15 @@ | ||
// @@START_GENERATED_FUNCTIONS@@ | ||
function is_ExampleMessage(resource) { | ||
return ((resource.keys().hasAll([]) && resource.size() == 0)) || | ||
(resource.keys().hasAll(['foo']) && resource.size() == 1)) || | ||
(resource.keys().hasAll(['bar']) && resource.size() == 1)) || | ||
(resource.keys().hasAll(['baz']) && resource.size() == 1)) || | ||
(resource.keys().hasAll(['bar','foo']) && resource.size() == 2)) || | ||
(resource.keys().hasAll(['baz','foo']) && resource.size() == 2)) || | ||
(resource.keys().hasAll(['baz','bar']) && resource.size() == 2)) || | ||
(resource.keys().hasAll(['baz','bar','foo']) && resource.size() == 3))) && | ||
((resource.foo == null) || (resource.foo is string)) && | ||
((resource.bar == null) || (resource.bar is string)) && | ||
((resource.baz == null) || (resource.baz is string)); | ||
} | ||
// @@END_GENERATED_FUNCTIONS@@ |