(t *testing.T)
| 1997 | } |
| 1998 | |
| 1999 | func TestDecodeBase64_CorrectlyDecodes(t *testing.T) { |
| 2000 | t.Parallel() |
| 2001 | for _, tc := range base64Cases { |
| 2002 | t.Run(tc.name, func(t *testing.T) { |
| 2003 | got, err := script.Echo(tc.encoded).DecodeBase64().String() |
| 2004 | if err != nil { |
| 2005 | t.Fatal(err) |
| 2006 | } |
| 2007 | if got != tc.decoded { |
| 2008 | t.Logf("input %q incorrectly decoded:", tc.encoded) |
| 2009 | t.Error(cmp.Diff(tc.decoded, got)) |
| 2010 | } |
| 2011 | }) |
| 2012 | } |
| 2013 | } |
| 2014 | |
| 2015 | func TestEncodeBase64_FollowedByDecodeRecoversOriginal(t *testing.T) { |
| 2016 | t.Parallel() |
nothing calls this directly
no test coverage detected
searching dependent graphs…