@@ -614,6 +614,8 @@ func TestGetTokenAccountInfos_NoTokenAccounts(t *testing.T) {
614
614
}
615
615
616
616
func TestLinkAdditionalAccounts_HappyPath (t * testing.T ) {
617
+ t .Skip ("rpc disabled" )
618
+
617
619
env , cleanup := setup (t )
618
620
defer cleanup ()
619
621
@@ -656,6 +658,8 @@ func TestLinkAdditionalAccounts_HappyPath(t *testing.T) {
656
658
}
657
659
658
660
func TestLinkAdditionalAccounts_UserAccountsNotOpened (t * testing.T ) {
661
+ t .Skip ("rpc disabled" )
662
+
659
663
env , cleanup := setup (t )
660
664
defer cleanup ()
661
665
@@ -683,6 +687,8 @@ func TestLinkAdditionalAccounts_UserAccountsNotOpened(t *testing.T) {
683
687
}
684
688
685
689
func TestLinkAdditionalAccounts_InvalidSwapAuthority (t * testing.T ) {
690
+ t .Skip ("rpc disabled" )
691
+
686
692
ownerAccount := testutil .NewRandomAccount (t )
687
693
swapAuthorityAccount := testutil .NewRandomAccount (t )
688
694
expectedSwapUsdcAta , err := swapAuthorityAccount .ToAssociatedTokenAccount (common .UsdcMintAccount )
@@ -763,7 +769,7 @@ func TestUnauthenticatedRPC(t *testing.T) {
763
769
defer cleanup ()
764
770
765
771
ownerAccount := testutil .NewRandomAccount (t )
766
- swapAuthorityAccount := testutil .NewRandomAccount (t )
772
+ // swapAuthorityAccount := testutil.NewRandomAccount(t)
767
773
maliciousAccount := testutil .NewRandomAccount (t )
768
774
769
775
isCodeAccountReq := & accountpb.IsCodeAccountRequest {
@@ -790,23 +796,25 @@ func TestUnauthenticatedRPC(t *testing.T) {
790
796
_ , err = env .client .GetTokenAccountInfos (env .ctx , getTokenAccountInfosReq )
791
797
testutil .AssertStatusErrorWithCode (t , err , codes .Unauthenticated )
792
798
793
- for i := 0 ; i < 2 ; i ++ {
794
- linkReq := & accountpb.LinkAdditionalAccountsRequest {
795
- Owner : ownerAccount .ToProto (),
796
- SwapAuthority : swapAuthorityAccount .ToProto (),
797
- }
798
- reqBytes , err = proto .Marshal (linkReq )
799
- require .NoError (t , err )
800
- signatures := []* commonpb.Signature {
801
- {Value : ed25519 .Sign (ownerAccount .PrivateKey ().ToBytes (), reqBytes )},
802
- {Value : ed25519 .Sign (swapAuthorityAccount .PrivateKey ().ToBytes (), reqBytes )},
803
- }
804
- signatures [i ].Value = ed25519 .Sign (maliciousAccount .PrivateKey ().ToBytes (), reqBytes )
805
- linkReq .Signatures = signatures
799
+ /*
800
+ for i := 0; i < 2; i++ {
801
+ linkReq := &accountpb.LinkAdditionalAccountsRequest{
802
+ Owner: ownerAccount.ToProto(),
803
+ SwapAuthority: swapAuthorityAccount.ToProto(),
804
+ }
805
+ reqBytes, err = proto.Marshal(linkReq)
806
+ require.NoError(t, err)
807
+ signatures := []*commonpb.Signature{
808
+ {Value: ed25519.Sign(ownerAccount.PrivateKey().ToBytes(), reqBytes)},
809
+ {Value: ed25519.Sign(swapAuthorityAccount.PrivateKey().ToBytes(), reqBytes)},
810
+ }
811
+ signatures[i].Value = ed25519.Sign(maliciousAccount.PrivateKey().ToBytes(), reqBytes)
812
+ linkReq.Signatures = signatures
806
813
807
- _ , err = env .client .LinkAdditionalAccounts (env .ctx , linkReq )
808
- testutil .AssertStatusErrorWithCode (t , err , codes .Unauthenticated )
809
- }
814
+ _, err = env.client.LinkAdditionalAccounts(env.ctx, linkReq)
815
+ testutil.AssertStatusErrorWithCode(t, err, codes.Unauthenticated)
816
+ }
817
+ */
810
818
}
811
819
812
820
func setupAccountRecords (t * testing.T , env testEnv , ownerAccount , authorityAccount * common.Account , index uint64 , accountType commonpb.AccountType ) * common.AccountRecords {
0 commit comments