f-88: api: ressource /floating-ips, refus et affichage sur la VM #88
Signed-off-by: GnomeZworc <nicolas.boufidjeline@g3e.fr>
This commit is contained in:
parent
81686de6d6
commit
653b1b0277
15 changed files with 942 additions and 12 deletions
|
|
@ -14,7 +14,7 @@ import (
|
|||
)
|
||||
|
||||
// prefixes énumère les familles de ressources portant une clé /state.
|
||||
var prefixes = []string{"vpc/", "subnet/", "vm/", "nat-gateway/"}
|
||||
var prefixes = []string{"vpc/", "subnet/", "vm/", "nat-gateway/", "floating-ip/"}
|
||||
|
||||
// legacyStates traduit l'ancien vocabulaire (états VPC/subnet d'avant
|
||||
// l'unification, et états VM start/stop) vers l'enum courant.
|
||||
|
|
|
|||
|
|
@ -41,6 +41,8 @@ func TestMigrateStates_LegacyMapping(t *testing.T) {
|
|||
"nat creating": {"nat-gateway/ng-1", "creating", state.Error},
|
||||
"nat deleting": {"nat-gateway/ng-2", "deleting", state.Error},
|
||||
"nat running": {"nat-gateway/ng-3", "running", state.Running},
|
||||
"fip creating": {"floating-ip/fip-1", "creating", state.Error},
|
||||
"fip running": {"floating-ip/fip-2", "running", state.Running},
|
||||
}
|
||||
for _, c := range cases {
|
||||
kv.AddInDB(db, c.resource+"/state", c.from)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue