@@ -7,9 +7,10 @@ import (
77	"testing" 
88
99	"github.com/container-storage-interface/spec/lib/go/csi" 
10+ 	"github.com/linode/linodego" 
11+ 
1012	linodeclient "github.com/linode/linode-blockstorage-csi-driver/pkg/linode-client" 
1113	linodevolumes "github.com/linode/linode-blockstorage-csi-driver/pkg/linode-volumes" 
12- 	"github.com/linode/linodego" 
1314)
1415
1516//nolint:gocognit // As simple as possible. 
@@ -103,7 +104,7 @@ func TestListVolumes(t *testing.T) {
103104				var  linodeVolume  * linodego.Volume 
104105				for  _ , v  :=  range  tt .volumes  {
105106					key  :=  linodevolumes .CreateLinodeVolumeKey (v .ID , v .Label )
106- 					if  volume .VolumeId  ==  key .GetVolumeKey () {
107+ 					if  volume .GetVolumeId ()  ==  key .GetVolumeKey () {
107108						v  :=  v 
108109						linodeVolume  =  & v 
109110						break 
@@ -113,11 +114,11 @@ func TestListVolumes(t *testing.T) {
113114					t .Fatalf ("no matching linode volume for %#v" , volume )
114115				}
115116
116- 				if  want , got  :=  int64 (linodeVolume .Size << 30 ), volume .CapacityBytes ; want  !=  got  {
117+ 				if  want , got  :=  int64 (linodeVolume .Size << 30 ), volume .GetCapacityBytes () ; want  !=  got  {
117118					t .Errorf ("mismatched volume size: want=%d got=%d" , want , got )
118119				}
119120				for  _ , topology  :=  range  volume .GetAccessibleTopology () {
120- 					region , ok  :=  topology .Segments [VolumeTopologyRegion ]
121+ 					region , ok  :=  topology .GetSegments () [VolumeTopologyRegion ]
121122					if  ! ok  {
122123						t .Error ("region not set in volume topology" )
123124					}
@@ -131,7 +132,7 @@ func TestListVolumes(t *testing.T) {
131132					t .Error ("nil status" )
132133					continue 
133134				}
134- 				if  status .VolumeCondition . Abnormal  {
135+ 				if  status .GetVolumeCondition (). GetAbnormal ()  {
135136					t .Error ("abnormal volume condition" )
136137				}
137138
0 commit comments