(t *testing.T)
| 716 | } |
| 717 | |
| 718 | func TestDescriptionCaseRule_LowerPass(t *testing.T) { |
| 719 | r := &rule.DescriptionCaseRule{} |
| 720 | if err := r.Apply(lint.RuleSetting{Argument: casing.Lower}); err != nil { |
| 721 | t.Fatal(err) |
| 722 | } |
| 723 | _, ok := r.Validate(&mockCommit{description: "add new feature"}) |
| 724 | if !ok { |
| 725 | t.Error("lowercase description should pass") |
| 726 | } |
| 727 | } |
| 728 | |
| 729 | func TestDescriptionCaseRule_Fail(t *testing.T) { |
| 730 | r := &rule.DescriptionCaseRule{} |