(t *testing.T)
| 402 | } |
| 403 | |
| 404 | func TestFirstSplit(t *testing.T) { |
| 405 | m := MatchFile{ |
| 406 | SplitPath: []string{".php"}, |
| 407 | fsmap: &filesystems.FileSystemMap{}, |
| 408 | } |
| 409 | actual, remainder := m.firstSplit("index.PHP/somewhere") |
| 410 | expected := "index.PHP" |
| 411 | expectedRemainder := "/somewhere" |
| 412 | if actual != expected { |
| 413 | t.Errorf("Expected split %s but got %s", expected, actual) |
| 414 | } |
| 415 | if remainder != expectedRemainder { |
| 416 | t.Errorf("Expected remainder %s but got %s", expectedRemainder, remainder) |
| 417 | } |
| 418 | } |
| 419 | |
| 420 | var expressionTests = []struct { |
| 421 | name string |
nothing calls this directly
no test coverage detected