From 95399ca05b059c06c1025d0c26a8ac8ae9a69f21 Mon Sep 17 00:00:00 2001
From: Jecket1 <134037206+Jecket1@users.noreply.github.com>
Date: Wed, 3 Jul 2024 15:11:37 +0800
Subject: [PATCH] Batch approve of NFTs (#159)
* Add sonar config
* Batch Approve NFTs
---
.github/workflows/sonarqube.yaml | 46 ++++++++++++
.../Forest.Contracts.Auction.csproj | 2 +-
.../Forest.Contracts.Drop.csproj | 2 +-
.../Forest.Contracts.Inscription.csproj | 12 +--
.../Forest.Contracts.SymbolRegistrar.csproj | 8 +-
.../Forest.Whitelist/Forest.Whitelist.csproj | 3 +
contract/Forest/Forest.csproj | 8 +-
contract/Forest/ForestContract_Helpers.cs | 10 +++
protobuf/token_contract.proto | 60 ++++++++++-----
protobuf/token_contract_impl.proto | 73 +++++++++++++------
.../Forest.Contracts.Auction.Tests.csproj | 2 +-
.../Forest.Contracts.Drop.Tests.csproj | 8 +-
.../Forest.Contracts.Inscription.Tests.csproj | 17 +++--
....Contracts.MockProxyAccountContract.csproj | 9 ++-
.../MockProxyAccountContract.cs | 1 -
...est.Contracts.SymbolRegistrar.Tests.csproj | 17 +++--
test/Forest.Tests/Forest.Tests.csproj | 17 +++--
.../Forest.Whitelist.Tests.csproj | 4 +
18 files changed, 209 insertions(+), 90 deletions(-)
create mode 100644 .github/workflows/sonarqube.yaml
mode change 100755 => 100644 protobuf/token_contract.proto
mode change 100755 => 100644 protobuf/token_contract_impl.proto
diff --git a/.github/workflows/sonarqube.yaml b/.github/workflows/sonarqube.yaml
new file mode 100644
index 00000000..a82adcb2
--- /dev/null
+++ b/.github/workflows/sonarqube.yaml
@@ -0,0 +1,46 @@
+on:
+ pull_request:
+ types: [opened, synchronize, reopened]
+
+name: PR Static Code Analysis
+jobs:
+ static-code-analysis:
+ runs-on: ubuntu-latest
+ steps:
+ - name: Code Checkout
+ uses: actions/checkout@v4
+ with:
+ fetch-depth: 0
+ - uses: actions/setup-dotnet@v4
+ with:
+ dotnet-version: '7.0.410'
+ - name: Create temporary global.json
+ run: echo '{"sdk":{"version":"7.0.410"}}' > ./global.json
+ - name: Install protobuf
+ run: sudo apt-get update && sudo apt-get install -y protobuf-compiler
+ - name: Set up JDK 17
+ uses: actions/setup-java@v1
+ with:
+ java-version: 17
+ - name: Cache SonarQube packages
+ uses: actions/cache@v1
+ with:
+ path: ~/.sonar/cache
+ key: ${{ runner.os }}-sonar
+ restore-keys: ${{ runner.os }}-sonar
+ - name: Cache SonarQube scanner
+ id: cache-sonar-scanner
+ uses: actions/cache@v1
+ with:
+ path: ./.sonar/scanner
+ key: ${{ runner.os }}-sonar-scanner
+ restore-keys: ${{ runner.os }}-sonar-scanner
+ - name: Install SonarScanner for .NET
+ run: dotnet tool update dotnet-sonarscanner --tool-path ./.sonar/scanner
+ - name: Add .NET global tools to PATH
+ run: echo "$HOME/.dotnet/tools" >> $GITHUB_PATH
+ - name: Begin SonarQube analysis
+ run: |
+ ./.sonar/scanner/dotnet-sonarscanner begin /k:"forest-contract" /d:sonar.host.url="${{ secrets.SONAR_HOST_URL }}" /d:sonar.token="${{ secrets.SONAR_TOKEN }}"
+ dotnet build
+ ./.sonar/scanner/dotnet-sonarscanner end /d:sonar.token="${{ secrets.SONAR_TOKEN }}"
\ No newline at end of file
diff --git a/contract/Forest.Contracts.Auction/Forest.Contracts.Auction.csproj b/contract/Forest.Contracts.Auction/Forest.Contracts.Auction.csproj
index 82e710ec..f2368846 100644
--- a/contract/Forest.Contracts.Auction/Forest.Contracts.Auction.csproj
+++ b/contract/Forest.Contracts.Auction/Forest.Contracts.Auction.csproj
@@ -20,7 +20,7 @@
Protobuf\Proto\acs0.proto
- Protobuf\Proto\token_contract.proto
+ Protobuf\Proto\reference\token_contract.proto
diff --git a/contract/Forest.Contracts.Drop/Forest.Contracts.Drop.csproj b/contract/Forest.Contracts.Drop/Forest.Contracts.Drop.csproj
index bf1caa0f..e5931acd 100644
--- a/contract/Forest.Contracts.Drop/Forest.Contracts.Drop.csproj
+++ b/contract/Forest.Contracts.Drop/Forest.Contracts.Drop.csproj
@@ -23,7 +23,7 @@
Protobuf\Proto\proxy_account_contract.proto
- Protobuf\Proto\token_contract.proto
+ Protobuf\Proto\reference\token_contract.proto
diff --git a/contract/Forest.Contracts.Inscription/Forest.Contracts.Inscription.csproj b/contract/Forest.Contracts.Inscription/Forest.Contracts.Inscription.csproj
index 3aec4222..25b7472c 100644
--- a/contract/Forest.Contracts.Inscription/Forest.Contracts.Inscription.csproj
+++ b/contract/Forest.Contracts.Inscription/Forest.Contracts.Inscription.csproj
@@ -22,15 +22,9 @@
-
- Protobuf\Proto\reference\token_contract.proto
-
Protobuf\Proto\reference\acs0.proto
-
- Protobuf\Proto\reference\token_contract_impl.proto
-
Protobuf\Proto\reference\acs1.proto
@@ -40,6 +34,12 @@
Protobuf\Proto\reference\transaction_fee.proto
+
+ Protobuf\Proto\reference\token_contract.proto
+
+
+ Protobuf\Proto\reference\token_contract_impl.proto
+
diff --git a/contract/Forest.Contracts.SymbolRegistrar/Forest.Contracts.SymbolRegistrar.csproj b/contract/Forest.Contracts.SymbolRegistrar/Forest.Contracts.SymbolRegistrar.csproj
index 50e90543..fe15d2b9 100644
--- a/contract/Forest.Contracts.SymbolRegistrar/Forest.Contracts.SymbolRegistrar.csproj
+++ b/contract/Forest.Contracts.SymbolRegistrar/Forest.Contracts.SymbolRegistrar.csproj
@@ -25,9 +25,6 @@
Protobuf\Proto\authority_info.proto
-
- Protobuf\Proto\token_contract.proto
-
Protobuf\Proto\parliament_contract.proto
@@ -41,7 +38,7 @@
Protobuf\Proto\authority_info.proto
- Protobuf\Proto\token_contract.proto
+ Protobuf\Proto\reference\token_contract.proto
@@ -54,4 +51,7 @@
Protobuf\Proto\symbol_registrar_contract.proto
+
+
+
\ No newline at end of file
diff --git a/contract/Forest.Whitelist/Forest.Whitelist.csproj b/contract/Forest.Whitelist/Forest.Whitelist.csproj
index 7829b035..4d313700 100644
--- a/contract/Forest.Whitelist/Forest.Whitelist.csproj
+++ b/contract/Forest.Whitelist/Forest.Whitelist.csproj
@@ -35,4 +35,7 @@
Protobuf\Proto\whitelist_contract.proto
+
+
+
diff --git a/contract/Forest/Forest.csproj b/contract/Forest/Forest.csproj
index 78d18bf8..5437a4e3 100755
--- a/contract/Forest/Forest.csproj
+++ b/contract/Forest/Forest.csproj
@@ -20,18 +20,16 @@
Protobuf\Proto\authority_info.proto
-
Protobuf\Proto\reference\acs12.proto
-
- Protobuf\Proto\reference\token_contract.proto
-
Protobuf\Proto\reference\whitelist_contract.proto
-
+
+ Protobuf\Proto\reference\token_contract.proto
+
diff --git a/contract/Forest/ForestContract_Helpers.cs b/contract/Forest/ForestContract_Helpers.cs
index 98fbcc3e..26661f7b 100644
--- a/contract/Forest/ForestContract_Helpers.cs
+++ b/contract/Forest/ForestContract_Helpers.cs
@@ -291,6 +291,16 @@ private long GetAllowance(Address address, string symbol)
{
Assert(address != null, $"Invalid param Address");
Assert(symbol != null, $"Invalid param Symbol");
+ var availableAllowance = State.TokenContract.GetAvailableAllowance.Call(new GetAllowanceInput
+ {
+ Symbol = symbol,
+ Owner = address,
+ Spender = Context.Self
+ });
+ if (availableAllowance?.Allowance != null && availableAllowance.Allowance > 0)
+ {
+ return availableAllowance.Allowance;
+ }
var allowance = State.TokenContract.GetAllowance.Call(new GetAllowanceInput
{
Symbol = symbol,
diff --git a/protobuf/token_contract.proto b/protobuf/token_contract.proto
old mode 100755
new mode 100644
index 5082990a..9931b680
--- a/protobuf/token_contract.proto
+++ b/protobuf/token_contract.proto
@@ -40,7 +40,10 @@ service TokenContract {
// enabling the Spender to call TransferFrom.
rpc Approve (ApproveInput) returns (google.protobuf.Empty) {
}
-
+
+ rpc BatchApprove (BatchApproveInput) returns (google.protobuf.Empty) {
+ }
+
// This is the reverse operation for Approve, it will decrease the allowance.
rpc UnApprove (UnApproveInput) returns (google.protobuf.Empty) {
}
@@ -141,6 +144,9 @@ service TokenContract {
rpc RemoveTransactionFeeDelegatee (RemoveTransactionFeeDelegateeInput) returns (google.protobuf.Empty){
}
+ rpc SetSymbolAlias (SetSymbolAliasInput) returns (google.protobuf.Empty){
+ }
+
// Get all delegatees' address of delegator from input
rpc GetTransactionFeeDelegatees (GetTransactionFeeDelegateesInput) returns (GetTransactionFeeDelegateesOutput) {
option (aelf.is_view) = true;
@@ -171,6 +177,11 @@ service TokenContract {
option (aelf.is_view) = true;
}
+ // Query the account's available allowance for other addresses
+ rpc GetAvailableAllowance (GetAllowanceInput) returns (GetAllowanceOutput) {
+ option (aelf.is_view) = true;
+ }
+
// Check whether the token is in the whitelist of an address,
// which can be called TransferFrom to transfer the token under the condition of not being credited.
rpc IsInWhiteList (IsInWhiteListInput) returns (google.protobuf.BoolValue) {
@@ -226,6 +237,14 @@ service TokenContract {
rpc GetTransactionFeeDelegationsOfADelegatee(GetTransactionFeeDelegationsOfADelegateeInput) returns(TransactionFeeDelegations){
option (aelf.is_view) = true;
}
+
+ rpc GetTokenAlias (google.protobuf.StringValue) returns (google.protobuf.StringValue) {
+ option (aelf.is_view) = true;
+ }
+
+ rpc GetSymbolByAlias (google.protobuf.StringValue) returns (google.protobuf.StringValue) {
+ option (aelf.is_view) = true;
+ }
}
message TokenInfo {
@@ -354,6 +373,9 @@ message ApproveInput {
// The amount of token to approve.
int64 amount = 3;
}
+message BatchApproveInput {
+ repeated ApproveInput value = 1;
+}
message UnApproveInput {
// The address that allowance will be decreased.
@@ -632,19 +654,6 @@ message TotalResourceTokensMap
map value = 1;
}
-message ChangeTokenIssuerInput
-{
- // The token symbol.
- string symbol = 1;
- // The new token issuer for change.
- aelf.Address new_token_Issuer = 2;
-}
-
-message ResetExternalInfoInput {
- string symbol = 1;
- ExternalInfo external_info = 2;
-}
-
message StringList {
repeated string value = 1;
}
@@ -696,6 +705,11 @@ message GetTransactionFeeDelegateesOutput {
repeated aelf.Address delegatee_addresses = 1;
}
+message SetSymbolAliasInput {
+ string symbol = 1;
+ string alias = 2;
+}
+
// Events
message Transferred {
@@ -853,12 +867,6 @@ message CrossChainReceived {
aelf.Hash transfer_transaction_id =9;
}
-message ExternalInfoChanged {
- option (aelf.is_event) = true;
- string symbol = 1;
- ExternalInfo external_info = 2;
-}
-
message TransactionFeeDelegationAdded {
option (aelf.is_event) = true;
aelf.Address delegator = 1 [(aelf.is_indexed) = true];
@@ -871,4 +879,16 @@ message TransactionFeeDelegationCancelled {
aelf.Address delegator = 1 [(aelf.is_indexed) = true];
aelf.Address delegatee = 2 [(aelf.is_indexed) = true];
aelf.Address caller = 3 [(aelf.is_indexed) = true];
+}
+
+message SymbolAliasAdded {
+ option (aelf.is_event) = true;
+ string symbol = 1 [(aelf.is_indexed) = true];
+ string alias = 2 [(aelf.is_indexed) = true];
+}
+
+message SymbolAliasDeleted {
+ option (aelf.is_event) = true;
+ string symbol = 1 [(aelf.is_indexed) = true];
+ string alias = 2 [(aelf.is_indexed) = true];
}
\ No newline at end of file
diff --git a/protobuf/token_contract_impl.proto b/protobuf/token_contract_impl.proto
old mode 100755
new mode 100644
index 56f50849..5885914e
--- a/protobuf/token_contract_impl.proto
+++ b/protobuf/token_contract_impl.proto
@@ -24,11 +24,11 @@ service TokenContractImpl {
option (aelf.base) = "acs1.proto";
option (aelf.base) = "acs2.proto";
option (aelf.base) = "token_contract.proto";
-
+
// Transfer resource tokens to designated contract address.
rpc AdvanceResourceToken (AdvanceResourceTokenInput) returns (google.protobuf.Empty) {
}
-
+
// Take token from contract address.
rpc TakeResourceTokenBack (TakeResourceTokenBackInput) returns (google.protobuf.Empty) {
}
@@ -36,15 +36,15 @@ service TokenContractImpl {
// Register the token contract address for cross chain.
rpc RegisterCrossChainTokenContractAddress (RegisterCrossChainTokenContractAddressInput) returns (google.protobuf.Empty) {
}
-
+
// Set the receiver address of the side chain transaction fee.
rpc SetFeeReceiver (aelf.Address) returns (google.protobuf.Empty) {
}
-
+
// Validates if the token exist.
rpc ValidateTokenInfoExists(ValidateTokenInfoExistsInput) returns (google.protobuf.Empty){
}
-
+
// Update the rental unit price of the side chain.
rpc UpdateRental (UpdateRentalInput) returns (google.protobuf.Empty) {
}
@@ -56,23 +56,23 @@ service TokenContractImpl {
// Transfer Token to the specified contract.
rpc TransferToContract (TransferToContractInput) returns (google.protobuf.Empty) {
}
-
+
// Change the governance organization of side chain rental.
rpc ChangeSideChainRentalController (AuthorityInfo) returns (google.protobuf.Empty) {
}
-
+
// Change the governance organization for tokens to pay transaction fees.
rpc ChangeSymbolsToPayTXSizeFeeController(AuthorityInfo) returns (google.protobuf.Empty){
}
-
+
// Change the governance organization for cross-chain token contract address registration.
rpc ChangeCrossChainTokenContractRegistrationController (AuthorityInfo) returns (google.protobuf.Empty) {
}
-
+
// Change the governance organization of the coefficient of the user transaction fee calculation formula.
rpc ChangeUserFeeController (AuthorityInfo) returns (google.protobuf.Empty) {
}
-
+
// Change the governance organization of the coefficient of the developer's transaction resource fee calculation formula.
rpc ChangeDeveloperController (AuthorityInfo) returns (google.protobuf.Empty) {
}
@@ -83,14 +83,19 @@ service TokenContractImpl {
rpc RemoveTransactionFeeFreeAllowancesConfig (RemoveTransactionFeeFreeAllowancesConfigInput) returns (google.protobuf.Empty) {
}
+ rpc SetMaxBatchApproveCount (google.protobuf.Int32Value) returns (google.protobuf.Empty) {
+
+ }
+
+
// Delegatee sets the delegation and related information of the delegator based on a transaction.
rpc SetTransactionFeeDelegateInfos (SetTransactionFeeDelegateInfosInput) returns (google.protobuf.Empty){
}
-
+
// Delegatee remove delegator info based on a transaction.
rpc RemoveTransactionFeeDelegatorInfos (RemoveTransactionFeeDelegatorInfosInput) returns (google.protobuf.Empty){
}
-
+
// Delegator remove delegatee info based on a transaction.
rpc RemoveTransactionFeeDelegateeInfos (RemoveTransactionFeeDelegateeInfosInput) returns (google.protobuf.Empty){
}
@@ -99,48 +104,48 @@ service TokenContractImpl {
rpc GetFeeReceiver (google.protobuf.Empty) returns (aelf.Address){
option (aelf.is_view) = true;
}
-
+
// Query the amount of resources usage currently.
rpc GetResourceUsage (google.protobuf.Empty) returns (ResourceUsage) {
option (aelf.is_view) = true;
}
-
+
// Query the governance organization for tokens to pay transaction fees.
rpc GetSymbolsToPayTXSizeFeeController(google.protobuf.Empty) returns (AuthorityInfo){
option (aelf.is_view) = true;
}
-
+
// Query the governance organization of the
rpc GetCrossChainTokenContractRegistrationController (google.protobuf.Empty) returns (AuthorityInfo) {
option (aelf.is_view) = true;
}
-
+
// Query the governance organization that calculates the formula coefficient
// for the transaction cost the user sends the contract.
rpc GetUserFeeController(google.protobuf.Empty) returns (UserFeeController){
option (aelf.is_view) = true;
}
-
+
// Query the governing organization of the formula coefficients for calculating developer contract transaction fee.
rpc GetDeveloperFeeController (google.protobuf.Empty) returns (DeveloperFeeController) {
option (aelf.is_view) = true;
}
-
+
// Query the organization that governs the side chain rental fee.
rpc GetSideChainRentalControllerCreateInfo (google.protobuf.Empty) returns (AuthorityInfo) {
option (aelf.is_view) = true;
}
-
+
// Compute the virtual address for locking.
rpc GetVirtualAddressForLocking (GetVirtualAddressForLockingInput) returns (aelf.Address) {
option (aelf.is_view) = true;
}
-
+
// Query how much resource tokens should be paid currently.
rpc GetOwningRental (google.protobuf.Empty) returns (OwningRental) {
option (aelf.is_view) = true;
}
-
+
// Query the unit price of the side chain resource cost, resource cost = unit price * quantity,
// the quantity can be queried through GetResourceUsage.
rpc GetOwningRentalUnitValue (google.protobuf.Empty) returns (OwningRentalUnitValue) {
@@ -154,7 +159,7 @@ service TokenContractImpl {
rpc GetTransactionFeeFreeAllowancesConfig (google.protobuf.Empty) returns (GetTransactionFeeFreeAllowancesConfigOutput) {
option (aelf.is_view) = true;
}
-
+
// Get delegatee info list according to the delegator and transaction.
rpc GetTransactionFeeDelegateeList (GetTransactionFeeDelegateeListInput) returns (GetTransactionFeeDelegateeListOutput) {
option (aelf.is_view) = true;
@@ -163,6 +168,20 @@ service TokenContractImpl {
rpc GetTransactionFeeDelegateInfo(GetTransactionFeeDelegateInfoInput) returns (token.TransactionFeeDelegations){
option (aelf.is_view) = true;
}
+
+ rpc ModifyTokenIssuerAndOwner(ModifyTokenIssuerAndOwnerInput) returns (google.protobuf.Empty) {
+ }
+
+ rpc SetTokenIssuerAndOwnerModificationEnabled(SetTokenIssuerAndOwnerModificationEnabledInput) returns (google.protobuf.Empty) {
+ }
+
+ rpc GetTokenIssuerAndOwnerModificationEnabled(google.protobuf.Empty) returns (google.protobuf.BoolValue) {
+ option (aelf.is_view) = true;
+ }
+
+ rpc GetMaxBatchApproveCount (google.protobuf.Empty) returns (google.protobuf.Int32Value) {
+
+ }
}
message AdvanceResourceTokenInput {
@@ -416,3 +435,13 @@ message TransactionFeeDelegateInfoCancelled {
aelf.Address caller = 3 ;
DelegateTransactionList delegate_transaction_list = 4;
}
+
+message ModifyTokenIssuerAndOwnerInput {
+ string symbol = 1;
+ aelf.Address issuer = 2;
+ aelf.Address owner = 3;
+}
+
+message SetTokenIssuerAndOwnerModificationEnabledInput{
+ bool enabled = 1;
+}
\ No newline at end of file
diff --git a/test/Forest.Contracts.Auction.Tests/Forest.Contracts.Auction.Tests.csproj b/test/Forest.Contracts.Auction.Tests/Forest.Contracts.Auction.Tests.csproj
index da1af05e..a2074dc5 100644
--- a/test/Forest.Contracts.Auction.Tests/Forest.Contracts.Auction.Tests.csproj
+++ b/test/Forest.Contracts.Auction.Tests/Forest.Contracts.Auction.Tests.csproj
@@ -33,7 +33,6 @@
-
@@ -66,6 +65,7 @@
+
\ No newline at end of file
diff --git a/test/Forest.Contracts.Drop.Tests/Forest.Contracts.Drop.Tests.csproj b/test/Forest.Contracts.Drop.Tests/Forest.Contracts.Drop.Tests.csproj
index 0ea3ecbc..3dadcd0b 100644
--- a/test/Forest.Contracts.Drop.Tests/Forest.Contracts.Drop.Tests.csproj
+++ b/test/Forest.Contracts.Drop.Tests/Forest.Contracts.Drop.Tests.csproj
@@ -33,7 +33,6 @@
-
@@ -47,15 +46,15 @@
Protobuf\Proto\acs1.proto
+
+ Protobuf\Proto\drop_contract.proto
+
Protobuf\Proto\token_contract.proto
Protobuf\Proto\token_contract_impl.proto
-
- Protobuf\Proto\drop_contract.proto
-
@@ -66,6 +65,7 @@
+
\ No newline at end of file
diff --git a/test/Forest.Contracts.Inscription.Tests/Forest.Contracts.Inscription.Tests.csproj b/test/Forest.Contracts.Inscription.Tests/Forest.Contracts.Inscription.Tests.csproj
index 153ca353..2a9122b6 100644
--- a/test/Forest.Contracts.Inscription.Tests/Forest.Contracts.Inscription.Tests.csproj
+++ b/test/Forest.Contracts.Inscription.Tests/Forest.Contracts.Inscription.Tests.csproj
@@ -13,7 +13,6 @@
-
@@ -50,12 +49,6 @@
Protobuf\Proto\inscription_contract.proto
-
- Protobuf\Proto\token_contract.proto
-
-
- Protobuf\Proto\token_contract_impl.proto
-
Protobuf\Proto\acs3.proto
@@ -107,6 +100,12 @@
Protobuf\Proto\acs7.proto
+
+ Protobuf\Proto\token_contract.proto
+
+
+ Protobuf\Proto\token_contract_impl.proto
+
@@ -115,4 +114,8 @@
+
+
+
+
\ No newline at end of file
diff --git a/test/Forest.Contracts.MockProxyAccountContract/Forest.Contracts.MockProxyAccountContract.csproj b/test/Forest.Contracts.MockProxyAccountContract/Forest.Contracts.MockProxyAccountContract.csproj
index 4484e932..e266de35 100644
--- a/test/Forest.Contracts.MockProxyAccountContract/Forest.Contracts.MockProxyAccountContract.csproj
+++ b/test/Forest.Contracts.MockProxyAccountContract/Forest.Contracts.MockProxyAccountContract.csproj
@@ -21,9 +21,6 @@
Protobuf\Proto\symbol_registrar_contract.proto
-
- Protobuf\Proto\token_contract.proto
-
@@ -37,7 +34,11 @@
-
+
+
+ Protobuf\Proto\reference\token_contract.proto
+
+
\ No newline at end of file
diff --git a/test/Forest.Contracts.MockProxyAccountContract/MockProxyAccountContract.cs b/test/Forest.Contracts.MockProxyAccountContract/MockProxyAccountContract.cs
index f334851c..216e97fb 100644
--- a/test/Forest.Contracts.MockProxyAccountContract/MockProxyAccountContract.cs
+++ b/test/Forest.Contracts.MockProxyAccountContract/MockProxyAccountContract.cs
@@ -1,7 +1,6 @@
using AElf.Contracts.MultiToken;
using AElf.Sdk.CSharp;
using AElf.Types;
-using Forest.Contracts.MockProxyAccountContract;
using Google.Protobuf.WellKnownTypes;
namespace Forest.Contracts.MockProxyAccountContract
diff --git a/test/Forest.Contracts.SymbolRegistrar.Tests/Forest.Contracts.SymbolRegistrar.Tests.csproj b/test/Forest.Contracts.SymbolRegistrar.Tests/Forest.Contracts.SymbolRegistrar.Tests.csproj
index f8f824c7..945ec082 100644
--- a/test/Forest.Contracts.SymbolRegistrar.Tests/Forest.Contracts.SymbolRegistrar.Tests.csproj
+++ b/test/Forest.Contracts.SymbolRegistrar.Tests/Forest.Contracts.SymbolRegistrar.Tests.csproj
@@ -33,7 +33,6 @@
-
@@ -82,12 +81,6 @@
Protobuf\Proto\symbol_registrar_contract.proto
-
- Protobuf\Proto\token_contract.proto
-
-
- Protobuf\Proto\token_contract_impl.proto
-
Protobuf\Generated\Protobuf\Proto\association_contract.proto
@@ -103,6 +96,12 @@
Protobuf\Proto\proxy_account_contract.proto
+
+ Protobuf\Proto\token_contract.proto
+
+
+ Protobuf\Proto\token_contract_impl.proto
+
@@ -111,5 +110,9 @@
+
+
+
+
\ No newline at end of file
diff --git a/test/Forest.Tests/Forest.Tests.csproj b/test/Forest.Tests/Forest.Tests.csproj
index 5deaf7f0..93f107f6 100755
--- a/test/Forest.Tests/Forest.Tests.csproj
+++ b/test/Forest.Tests/Forest.Tests.csproj
@@ -11,7 +11,6 @@
-
@@ -47,12 +46,6 @@
Protobuf\Proto\forest_contract.proto
-
- Protobuf\Proto\token_contract.proto
-
-
- Protobuf\Proto\token_contract_impl.proto
-
Protobuf\Proto\acs3.proto
@@ -74,6 +67,12 @@
Protobuf\Proto\whitelist_contract.proto
+
+ Protobuf\Proto\token_contract.proto
+
+
+ Protobuf\Proto\token_contract_impl.proto
+
Protobuf\Proto\acs0.proto
@@ -98,4 +97,8 @@
+
+
+
+
\ No newline at end of file
diff --git a/test/Forest.Whitelist.Tests/Forest.Whitelist.Tests.csproj b/test/Forest.Whitelist.Tests/Forest.Whitelist.Tests.csproj
index 70e046a9..b7de483e 100644
--- a/test/Forest.Whitelist.Tests/Forest.Whitelist.Tests.csproj
+++ b/test/Forest.Whitelist.Tests/Forest.Whitelist.Tests.csproj
@@ -63,4 +63,8 @@
+
+
+
+
\ No newline at end of file