(t *testing.T)
| 236 | } |
| 237 | |
| 238 | func TestWithAsciiBJunk(t *testing.T) { |
| 239 | isJunk := func(s string) bool { |
| 240 | return s == " " |
| 241 | } |
| 242 | sm := NewMatcherWithJunk(splitChars(rep("a", 40)+rep("b", 40)), |
| 243 | splitChars(rep("a", 44)+rep("b", 40)), true, isJunk) |
| 244 | assertEqual(t, sm.bJunk, map[string]struct{}{}) |
| 245 | |
| 246 | sm = NewMatcherWithJunk(splitChars(rep("a", 40)+rep("b", 40)), |
| 247 | splitChars(rep("a", 44)+rep("b", 40)+rep(" ", 20)), false, isJunk) |
| 248 | assertEqual(t, sm.bJunk, map[string]struct{}{" ": struct{}{}}) |
| 249 | |
| 250 | isJunk = func(s string) bool { |
| 251 | return s == " " || s == "b" |
| 252 | } |
| 253 | sm = NewMatcherWithJunk(splitChars(rep("a", 40)+rep("b", 40)), |
| 254 | splitChars(rep("a", 44)+rep("b", 40)+rep(" ", 20)), false, isJunk) |
| 255 | assertEqual(t, sm.bJunk, map[string]struct{}{" ": struct{}{}, "b": struct{}{}}) |
| 256 | } |
| 257 | |
| 258 | func TestSFBugsRatioForNullSeqn(t *testing.T) { |
| 259 | sm := NewMatcher(nil, nil) |
nothing calls this directly
no test coverage detected
searching dependent graphs…