(t *testing.T)
| 1221 | } |
| 1222 | |
| 1223 | func TestSignedOffBy_Missing_Fail(t *testing.T) { |
| 1224 | r := &rule.SignedOffByRule{} |
| 1225 | if err := r.Apply(lint.RuleSetting{Argument: "Signed-off-by:"}); err != nil { |
| 1226 | t.Fatal(err) |
| 1227 | } |
| 1228 | _, ok := r.Validate(&mockCommit{}) |
| 1229 | if ok { |
| 1230 | t.Error("commit without Signed-off-by note should fail") |
| 1231 | } |
| 1232 | } |
| 1233 | |
| 1234 | func TestSignedOffBy_NoColon_Missing_Fail(t *testing.T) { |
| 1235 | r := &rule.SignedOffByRule{} |