@@ -1002,7 +1002,7 @@ func CheckPublicParamsMatch(network *integration.Infrastructure, tmsId *token2.T
10021002}
10031003
10041004func GetTMSByNetworkName (network * integration.Infrastructure , networkName string ) * topology.TMS {
1005- tp := tplatform .GetPlatform (network .Ctx , "token" )
1005+ tp := tplatform .GetPlatform (network .NWOCtx , "token" )
10061006 gomega .Expect (tp ).NotTo (gomega .BeNil ())
10071007 for _ , TMS := range tp .GetTopology ().TMSs {
10081008 if TMS .Network == networkName {
@@ -1013,7 +1013,7 @@ func GetTMSByNetworkName(network *integration.Infrastructure, networkName string
10131013}
10141014
10151015func GetTMSByTMSID (network * integration.Infrastructure , tmsID token2.TMSID ) * topology.TMS {
1016- tp := tplatform .GetPlatform (network .Ctx , "token" )
1016+ tp := tplatform .GetPlatform (network .NWOCtx , "token" )
10171017 gomega .Expect (tp ).NotTo (gomega .BeNil ())
10181018 for _ , tms := range tp .GetTopology ().TMSs {
10191019 if tms .Network == tmsID .Network && tms .Channel == tmsID .Channel && tms .Namespace == tmsID .Namespace {
@@ -1024,7 +1024,7 @@ func GetTMSByTMSID(network *integration.Infrastructure, tmsID token2.TMSID) *top
10241024}
10251025
10261026func GetTMSByAlias (network * integration.Infrastructure , alias topology.TMSAlias ) * topology.TMS {
1027- tp := tplatform .GetPlatform (network .Ctx , "token" )
1027+ tp := tplatform .GetPlatform (network .NWOCtx , "token" )
10281028 gomega .Expect (tp ).NotTo (gomega .BeNil ())
10291029 for _ , TMS := range tp .GetTopology ().TMSs {
10301030 if TMS .Alias == alias {
@@ -1035,12 +1035,12 @@ func GetTMSByAlias(network *integration.Infrastructure, alias topology.TMSAlias)
10351035}
10361036
10371037func UpdatePublicParams (network * integration.Infrastructure , publicParams []byte , tms * topology.TMS ) {
1038- p := network .Ctx .PlatformsByName ["token" ]
1038+ p := network .NWOCtx .PlatformsByName ["token" ]
10391039 p .(* tplatform.Platform ).UpdatePublicParams (tms , publicParams )
10401040}
10411041
10421042func UpdatePublicParamsAndWait (network * integration.Infrastructure , publicParams []byte , tms * topology.TMS , nodes ... * token3.NodeReference ) {
1043- p := network .Ctx .PlatformsByName ["token" ]
1043+ p := network .NWOCtx .PlatformsByName ["token" ]
10441044 p .(* tplatform.Platform ).UpdatePublicParams (tms , publicParams )
10451045 for _ , node := range nodes {
10461046 if node .Id () == "custodian" {
@@ -1217,15 +1217,15 @@ func Restart(network *integration.Infrastructure, deleteVault bool, onRestart On
12171217 time .Sleep (10 * time .Second )
12181218 if deleteVault {
12191219 for _ , id := range ids {
1220- for name , platform := range network .Ctx .PlatformsByName {
1220+ for name , platform := range network .NWOCtx .PlatformsByName {
12211221 if dv , ok := platform .(deleteVaultPlatform ); ok {
12221222 logger .Infof ("Platform %d supports delete vault. Deleting..." , name )
12231223 dv .DeleteVault (id .Id ())
12241224 }
12251225 }
12261226
12271227 // delete token dbs as well
1228- tokenPlatform := tplatform .GetPlatform (network .Ctx , "token" )
1228+ tokenPlatform := tplatform .GetPlatform (network .NWOCtx , "token" )
12291229 gomega .Expect (tokenPlatform ).ToNot (gomega .BeNil (), "cannot find token platform in context" )
12301230 for _ , tms := range tokenPlatform .GetTopology ().TMSs {
12311231 tokenPlatform .DeleteDBs (tms , id .Id ())
@@ -1249,7 +1249,7 @@ func Restart(network *integration.Infrastructure, deleteVault bool, onRestart On
12491249}
12501250
12511251func CopyDBsTo (network * integration.Infrastructure , to string , ids ... * token3.NodeReference ) {
1252- tokenPlatform := tplatform .GetPlatform (network .Ctx , "token" )
1252+ tokenPlatform := tplatform .GetPlatform (network .NWOCtx , "token" )
12531253 gomega .Expect (tokenPlatform ).ToNot (gomega .BeNil (), "cannot find token platform in context" )
12541254
12551255 for _ , id := range ids {
@@ -1265,7 +1265,7 @@ func RegisterIssuerIdentity(network *integration.Infrastructure, id *token3.Node
12651265 Path : walletPath ,
12661266 }))
12671267 gomega .Expect (err ).NotTo (gomega .HaveOccurred ())
1268- network .Ctx .SetViewClient (walletPath , network .Client (id .ReplicaName ()))
1268+ network .NWOCtx .SetViewClient (walletPath , network .Client (id .ReplicaName ()))
12691269}
12701270
12711271func RegisterOwnerIdentity (ctx context.Context , network * integration.Infrastructure , id * token3.NodeReference , identityConfiguration token2.IdentityConfiguration ) {
@@ -1274,7 +1274,7 @@ func RegisterOwnerIdentity(ctx context.Context, network *integration.Infrastruct
12741274 IdentityConfiguration : identityConfiguration ,
12751275 }))
12761276 gomega .Expect (err ).NotTo (gomega .HaveOccurred (), "cannot register owner identity at replica [%s]" , replicaName )
1277- network .Ctx .SetViewClient (identityConfiguration .ID , network .Client (replicaName ))
1277+ network .NWOCtx .SetViewClient (identityConfiguration .ID , network .Client (replicaName ))
12781278 }
12791279}
12801280
@@ -1284,7 +1284,7 @@ func RegisterRecipientData(network *integration.Infrastructure, ref *token3.Node
12841284 RecipientData : * rd ,
12851285 }))
12861286 gomega .Expect (err ).NotTo (gomega .HaveOccurred ())
1287- network .Ctx .SetViewClient (walletID , network .Client (ref .ReplicaName ()))
1287+ network .NWOCtx .SetViewClient (walletID , network .Client (ref .ReplicaName ()))
12881288}
12891289
12901290func CheckOwnerWalletIDs (network * integration.Infrastructure , owner * token3.NodeReference , ids ... string ) {
@@ -1507,7 +1507,7 @@ func PrepareUpdatedPublicParams(network *integration.Infrastructure, auditor str
15071507 auditorId := GetAuditorIdentity (tms , auditor )
15081508 issuerId := GetIssuerIdentity (tms , issuer )
15091509
1510- tokenPlatform , ok := network .Ctx .PlatformsByName ["token" ].(* tplatform.Platform )
1510+ tokenPlatform , ok := network .NWOCtx .PlatformsByName ["token" ].(* tplatform.Platform )
15111511 gomega .Expect (ok ).To (gomega .BeTrue (), "failed to get token platform from context" )
15121512
15131513 // Deserialize current params
@@ -1563,7 +1563,7 @@ func PreparePublicParamsWithNewIssuer(network *integration.Infrastructure, issue
15631563 wrap , err := identity .WrapWithType (x509 .IdentityType , identityDescriptor .Identity )
15641564 gomega .Expect (err ).NotTo (gomega .HaveOccurred ())
15651565
1566- tokenPlatform , ok := network .Ctx .PlatformsByName ["token" ].(* tplatform.Platform )
1566+ tokenPlatform , ok := network .NWOCtx .PlatformsByName ["token" ].(* tplatform.Platform )
15671567 gomega .Expect (ok ).To (gomega .BeTrue (), "failed to get token platform from context" )
15681568
15691569 // Deserialize current params
0 commit comments