diff --git a/docs/rules/0122/name-suffix.md b/docs/rules/0122/name-suffix.md index 1209156fd..f5e856c9e 100644 --- a/docs/rules/0122/name-suffix.md +++ b/docs/rules/0122/name-suffix.md @@ -18,7 +18,8 @@ This rule enforces that fields do not use the suffix `_name`, as mandated in This rule scans all fields complains if it sees the suffix `_name` on a field. **Note:** The standard field `display_name` is exempt, as are `given_name` and -`family_name` (used to represent the human-readable name of a person). +`family_name` (used to represent the human-readable name of a person), and +`full_resource_name`. ## Examples diff --git a/rules/aip0122/name_suffix.go b/rules/aip0122/name_suffix.go index 6f8b135e5..1371e1a63 100644 --- a/rules/aip0122/name_suffix.go +++ b/rules/aip0122/name_suffix.go @@ -30,6 +30,7 @@ var nameSuffix = &lint.FieldRule{ "display_name", "family_name", "given_name", + "full_resource_name", "name", ).Contains(f.GetName()) }, diff --git a/rules/aip0122/name_suffix_test.go b/rules/aip0122/name_suffix_test.go index 7ed8988da..688b2b3ab 100644 --- a/rules/aip0122/name_suffix_test.go +++ b/rules/aip0122/name_suffix_test.go @@ -30,6 +30,7 @@ func TestNameSuffix(t *testing.T) { {"ValidStandardDisplay", "display_name", testutils.Problems{}}, {"ValidStandardGiven", "given_name", testutils.Problems{}}, {"ValidStandardFamily", "family_name", testutils.Problems{}}, + {"ValidStandardFull", "full_resource_name", testutils.Problems{}}, {"Invalid", "author_name", testutils.Problems{{Suggestion: "author"}}}, } { f := testutils.ParseProto3Tmpl(t, `