]> Cypherpunks repositories - gostls13.git/commitdiff
encoding/pem: test getLine does not include trailing whitespace
authorSanthosh Kumar Tekuri <santhosh.tekuri@gmail.com>
Tue, 6 Feb 2018 06:30:13 +0000 (12:00 +0530)
committerIan Lance Taylor <iant@golang.org>
Mon, 19 Nov 2018 23:35:21 +0000 (23:35 +0000)
Change-Id: I7a1046f5e0aedbbdd1106a616de410fe4e0cb7d8
Reviewed-on: https://go-review.googlesource.com/c/92295
Run-TryBot: Ian Lance Taylor <iant@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
src/encoding/pem/pem_test.go

index a1b5afac0866d781e250714171b3ae942085bde6..204611bda02d7ac223891d503e934febaa246416 100644 (file)
@@ -26,6 +26,10 @@ var getLineTests = []GetLineTest{
        {"abc\r\nd", "abc", "d"},
        {"\nabc", "", "abc"},
        {"\r\nabc", "", "abc"},
+       {"abc\t \nd", "abc", "d"},
+       {"\t abc\nd", "\t abc", "d"},
+       {"abc\n\t d", "abc", "\t d"},
+       {"abc\nd\t ", "abc", "d\t "},
 }
 
 func TestGetLine(t *testing.T) {