forked from GoogleCloudPlatform/magic-modules
-
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.
Intentionally broke breaking change detector
- Loading branch information
Showing
1 changed file
with
0 additions
and
56 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 |
---|---|---|
@@ -1,56 +0,0 @@ | ||
package rules | ||
|
||
// Rule is an interface that all Rule | ||
// types implement. This give consistency | ||
// for the potential documentation generation. | ||
type Rule interface { | ||
Name() string | ||
Definition() string | ||
Identifier() string | ||
Undetectable() bool | ||
} | ||
|
||
// RuleCategory holds documentation and | ||
// inventory for each of the rule types | ||
type RuleCategory struct { | ||
Name string | ||
Definition string | ||
Rules []Rule | ||
} | ||
|
||
// Rules is a type to hold all existing | ||
// rules. Exposed for potential documentation generator | ||
type Rules struct { | ||
Categories []RuleCategory | ||
} | ||
|
||
// GetRules returns a list of all rules for | ||
// potential documentation generation | ||
func GetRules() *Rules { | ||
categories := []RuleCategory{ | ||
{ | ||
Name: "Provider Configuration Level Breakages", | ||
Definition: "Top level behavior such as provider configuration and authentication changes.", | ||
Rules: providerConfigRulesToRuleArray(ProviderConfigRules), | ||
}, | ||
{ | ||
Name: "Resource List Level Breakages", | ||
Definition: "Resource/datasource naming conventions and entry differences.", | ||
Rules: resourceInventoryRulesToRuleArray(ResourceInventoryRules), | ||
}, | ||
{ | ||
Name: "Resource Level Breakages", | ||
Definition: "Individual resource breakages like field entry removals or behavior within a resource.", | ||
Rules: resourceSchemaRulesToRuleArray(ResourceSchemaRules), | ||
}, | ||
{ | ||
Name: "Field Level Breakages", | ||
Definition: "Field level conventions like attribute changes and naming conventions.", | ||
Rules: fieldRulesToRuleArray(FieldRules), | ||
}, | ||
} | ||
|
||
return &Rules{ | ||
Categories: categories, | ||
} | ||
} | ||