Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(1254)

Unified Diff: utils/ssh/ssh_gocrypto_test.go

Issue 55950043: utils/ssh, provider/local: more reliable tests
Patch Set: utils/ssh, provider/local: more reliable tests Created 11 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « provider/local/environprovider_test.go ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: utils/ssh/ssh_gocrypto_test.go
=== modified file 'utils/ssh/ssh_gocrypto_test.go'
--- utils/ssh/ssh_gocrypto_test.go 2014-01-17 04:35:46 +0000
+++ utils/ssh/ssh_gocrypto_test.go 2014-01-23 08:42:05 +0000
@@ -101,16 +101,16 @@
func (s *SSHGoCryptoCommandSuite) TestClientNoKeys(c *gc.C) {
client, err := ssh.NewGoCryptoClient()
c.Assert(err, gc.IsNil)
- cmd := client.Command("test.invalid", []string{"echo", "123"}, nil)
+ cmd := client.Command("0.1.2.3", []string{"echo", "123"}, nil)
_, err = cmd.Output()
c.Assert(err, gc.ErrorMatches, "no private keys available")
defer ssh.ClearClientKeys()
err = ssh.LoadClientKeys(c.MkDir())
c.Assert(err, gc.IsNil)
- cmd = client.Command("test.invalid", []string{"echo", "123"}, nil)
+ cmd = client.Command("0.1.2.3", []string{"echo", "123"}, nil)
_, err = cmd.Output()
// error message differs based on whether using cgo or not
- c.Assert(err, gc.ErrorMatches, "(dial tcp: )?lookup test.invalid: no such host")
+ c.Assert(err, gc.ErrorMatches, `(dial tcp )?0\.1\.2\.3:22: invalid argument`)
}
func (s *SSHGoCryptoCommandSuite) TestCommand(c *gc.C) {
@@ -140,6 +140,6 @@
func (s *SSHGoCryptoCommandSuite) TestCopy(c *gc.C) {
client, err := ssh.NewGoCryptoClient()
c.Assert(err, gc.IsNil)
- err = client.Copy("test.invalid:b", c.MkDir(), nil)
+ err = client.Copy("0.1.2.3:b", c.MkDir(), nil)
c.Assert(err, gc.ErrorMatches, "Copy is not implemented")
}
« no previous file with comments | « provider/local/environprovider_test.go ('k') | no next file » | no next file with comments »

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b