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

Unified Diff: state/machine_test.go

Issue 85380043: state;api: Allow adding existing networks/NICs (Closed)
Patch Set: Created 9 years, 11 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 | « state/machine.go ('k') | state/state.go » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: state/machine_test.go
=== modified file 'state/machine_test.go'
--- state/machine_test.go 2014-04-04 11:04:48 +0000
+++ state/machine_test.go 2014-04-08 10:20:15 +0000
@@ -496,8 +496,9 @@
c.Assert(err, gc.ErrorMatches, expectErr)
_, err = machine.AddNetworkInterface("aa:bb:cc:dd:ee:f0", "eth2", "net1")
- expectErr = errorPrefix + `interface with MAC address "aa:bb:cc:dd:ee:f0" already exists`
+ expectErr = `interface with MAC address aa:bb:cc:dd:ee:f0 already exists`
c.Assert(err, gc.ErrorMatches, expectErr)
+ c.Assert(err, jc.Satisfies, errors.IsAlreadyExistsError)
_, err = machine.AddNetworkInterface("aa:bb:cc:dd:ee:f0", "eth2", "invalid")
expectErr = errorPrefix + `network "invalid" not found`
« no previous file with comments | « state/machine.go ('k') | state/state.go » ('j') | no next file with comments »

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