]> Sergey Matveev's repositories - path-extractor.git/commitdiff
Add failing test for filesize and git remote
authorEdgar HIPP <hipp.edg@gmail.com>
Sat, 16 Jan 2016 07:23:19 +0000 (08:23 +0100)
committerEdgar HIPP <hipp.edg@gmail.com>
Sat, 16 Jan 2016 07:23:19 +0000 (08:23 +0100)
pe_test.go

index dde9cf85de6df6f8275ed7dca7f3b895521ec6a1..677161c4f6f6b322d0a574dde7eef37888631276 100644 (file)
@@ -8,6 +8,26 @@ func TestEverything(t *testing.T) {
                t.Errorf("Doesnt match files", output)
        }
 
+       output = GetAllMatches("2.0G", "")
+       if len(output) != 0 {
+               t.Errorf("File size matches", output)
+       }
+
+       output = GetAllMatches("4.0K", "")
+       if len(output) != 0 {
+               t.Errorf("File size matches", output)
+       }
+
+       output = GetAllMatches("72K", "")
+       if len(output) != 0 {
+               t.Errorf("File size matches", output)
+       }
+
+       output = GetAllMatches("remotes/origin/master", "")
+       if len(output) != 0 {
+               t.Errorf("Git branch matches", output)
+       }
+
        output = GetAllMatches("I have a cat.", "")
        if len(output) != 0 {
                t.Errorf("Matches sentence", output)