(t *testing.T)
| 149 | } |
| 150 | |
| 151 | func (s) TestInfo(t *testing.T) { |
| 152 | // This is not testing any handshaker functionality, so it's fine to only |
| 153 | // use NewServerCreds and not NewClientCreds. |
| 154 | c := NewServerCreds(DefaultServerOptions()) |
| 155 | info := c.Info() |
| 156 | if got, want := info.SecurityProtocol, "alts"; got != want { |
| 157 | t.Errorf("info.SecurityProtocol=%v, want %v", got, want) |
| 158 | } |
| 159 | if got, want := info.SecurityVersion, "1.0"; got != want { |
| 160 | t.Errorf("info.SecurityVersion=%v, want %v", got, want) |
| 161 | } |
| 162 | if got, want := info.ServerName, ""; got != want { |
| 163 | t.Errorf("info.ServerName=%v, want %v", got, want) |
| 164 | } |
| 165 | } |
| 166 | |
| 167 | func (s) TestCompareRPCVersions(t *testing.T) { |
| 168 | for _, tc := range []struct { |
nothing calls this directly
no test coverage detected