From: Edgar HIPP Date: Sun, 30 Aug 2015 15:07:20 +0000 (+0200) Subject: Add new test X-Git-Url: http://www.git.stargrave.org/?p=path-extractor.git;a=commitdiff_plain;h=8c5300370a9311b9b5296854b04c69eaee135d00 Add new test --- diff --git a/pe_test.go b/pe_test.go index 2deeae7..5d447f4 100644 --- a/pe_test.go +++ b/pe_test.go @@ -103,6 +103,16 @@ func TestEverything(t *testing.T) { } output = GetAllMatches("and/or", MatchOptions{}) + if len(output) != 0 { + t.Errorf("Matches and/or", output[0]) + } + + output = GetAllMatches("hello user.test.js", MatchOptions{}) + if output[0] != "user.test.js" { + t.Errorf("Matches date", output[0]) + } + + output = GetAllMatches(" mail@mail.com ", MatchOptions{}) if len(output) != 0 { t.Errorf("Matches and/or adresses", output) }