44 "fmt"
55 "net/http"
66 "testing"
7+ "time"
78
89 "github.com/gophercloud/gophercloud/openstack/baremetal/v1/nodes"
910 th "github.com/gophercloud/gophercloud/testhelper"
@@ -143,7 +144,7 @@ const NodeListDetailBody = `
143144 "power_state": null,
144145 "properties": {},
145146 "provision_state": "enroll",
146- "provision_updated_at": null ,
147+ "provision_updated_at": "2019-02-15T17:21:29+00:00" ,
147148 "raid_config": {},
148149 "raid_interface": "no-raid",
149150 "rescue_interface": "no-rescue",
@@ -164,7 +165,7 @@ const NodeListDetailBody = `
164165 "target_provision_state": null,
165166 "target_raid_config": {},
166167 "traits": [],
167- "updated_at": null ,
168+ "updated_at": "2019-02-15T19:59:29+00:00" ,
168169 "uuid": "d2630783-6ec8-4836-b556-ab427c4b581e",
169170 "vendor_interface": "ipmitool",
170171 "volume": [
@@ -261,7 +262,7 @@ const NodeListDetailBody = `
261262 "target_provision_state": null,
262263 "target_raid_config": {},
263264 "traits": [],
264- "updated_at": null ,
265+ "updated_at": "2019-02-15T19:59:29+00:00" ,
265266 "uuid": "08c84581-58f5-4ea2-a0c6-dd2e5d2b3662",
266267 "vendor_interface": "ipmitool",
267268 "volume": [
@@ -358,7 +359,7 @@ const NodeListDetailBody = `
358359 "target_provision_state": null,
359360 "target_raid_config": {},
360361 "traits": [],
361- "updated_at": null ,
362+ "updated_at": "2019-02-15T19:59:29+00:00" ,
362363 "uuid": "c9afd385-5d89-4ecb-9e1c-68194da6b474",
363364 "vendor_interface": "ipmitool",
364365 "volume": [
@@ -447,7 +448,7 @@ const SingleNodeBody = `
447448 "power_state": null,
448449 "properties": {},
449450 "provision_state": "enroll",
450- "provision_updated_at": null ,
451+ "provision_updated_at": "2019-02-15T17:21:29+00:00" ,
451452 "raid_config": {},
452453 "raid_interface": "no-raid",
453454 "rescue_interface": "no-rescue",
@@ -468,7 +469,7 @@ const SingleNodeBody = `
468469 "target_provision_state": null,
469470 "target_raid_config": {},
470471 "traits": [],
471- "updated_at": null ,
472+ "updated_at": "2019-02-15T19:59:29+00:00" ,
472473 "uuid": "d2630783-6ec8-4836-b556-ab427c4b581e",
473474 "vendor_interface": "ipmitool",
474475 "volume": [
@@ -813,6 +814,12 @@ const NodeSetMaintenanceBody = `
813814`
814815
815816var (
817+ createdAtFoo , _ = time .Parse (time .RFC3339 , "2019-01-31T19:59:28+00:00" )
818+ createdAtBar , _ = time .Parse (time .RFC3339 , "2019-01-31T19:59:29+00:00" )
819+ createdAtBaz , _ = time .Parse (time .RFC3339 , "2019-01-31T19:59:30+00:00" )
820+ updatedAt , _ = time .Parse (time .RFC3339 , "2019-02-15T19:59:29+00:00" )
821+ provisonUpdatedAt , _ = time .Parse (time .RFC3339 , "2019-02-15T17:21:29+00:00" )
822+
816823 NodeFoo = nodes.Node {
817824 UUID : "d2630783-6ec8-4836-b556-ab427c4b581e" ,
818825 Name : "foo" ,
@@ -862,6 +869,9 @@ var (
862869 ConductorGroup : "" ,
863870 Protected : false ,
864871 ProtectedReason : "" ,
872+ CreatedAt : createdAtFoo ,
873+ UpdatedAt : updatedAt ,
874+ ProvisionUpdatedAt : provisonUpdatedAt ,
865875 }
866876
867877 NodeFooValidation = nodes.NodeValidation {
@@ -959,6 +969,8 @@ var (
959969 ConductorGroup : "" ,
960970 Protected : false ,
961971 ProtectedReason : "" ,
972+ CreatedAt : createdAtBar ,
973+ UpdatedAt : updatedAt ,
962974 }
963975
964976 NodeBaz = nodes.Node {
@@ -1003,6 +1015,8 @@ var (
10031015 ConductorGroup : "" ,
10041016 Protected : false ,
10051017 ProtectedReason : "" ,
1018+ CreatedAt : createdAtBaz ,
1019+ UpdatedAt : updatedAt ,
10061020 }
10071021
10081022 ConfigDriveMap = nodes.ConfigDrive {
0 commit comments