Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Dependency Update]this pr apply latest neo to devpack #948

Merged
merged 4 commits into from
Feb 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion neo
Submodule neo updated 53 files
+13 −3 .github/workflows/main.yml
+1 −2 benchmarks/Neo.Benchmarks/Benchmarks.cs
+34 −1,442 src/Neo.VM/ExecutionEngine.cs
+65 −0 src/Neo.VM/JumpTable/JumpTable.Bitwisee.cs
+390 −0 src/Neo.VM/JumpTable/JumpTable.Compound.cs
+396 −0 src/Neo.VM/JumpTable/JumpTable.Control.cs
+265 −0 src/Neo.VM/JumpTable/JumpTable.Numeric.cs
+213 −0 src/Neo.VM/JumpTable/JumpTable.Push.cs
+363 −0 src/Neo.VM/JumpTable/JumpTable.Slot.cs
+106 −0 src/Neo.VM/JumpTable/JumpTable.Splice.cs
+124 −0 src/Neo.VM/JumpTable/JumpTable.Stack.cs
+60 −0 src/Neo.VM/JumpTable/JumpTable.Types.cs
+71 −0 src/Neo.VM/JumpTable/JumpTable.cs
+1 −0 src/Neo.VM/Neo.VM.csproj
+2 −1 src/Neo/Hardfork.cs
+1 −0 src/Neo/Neo.csproj
+12 −7 src/Neo/NeoSystem.cs
+1 −1 src/Neo/Persistence/DataCache.cs
+19 −0 src/Neo/Persistence/MemoryStoreProvider.cs
+19 −10 src/Neo/Persistence/StoreFactory.cs
+47 −5 src/Neo/ProtocolSettings.cs
+1 −1 src/Neo/SmartContract/ApplicationEngine.Contract.cs
+92 −50 src/Neo/SmartContract/ApplicationEngine.cs
+3 −1 src/Neo/SmartContract/IApplicationEngineProvider.cs
+165 −0 src/Neo/SmartContract/Native/ContractEventAttribute.cs
+33 −56 src/Neo/SmartContract/Native/ContractManagement.cs
+10 −0 src/Neo/SmartContract/Native/ContractMethodAttribute.cs
+4 −0 src/Neo/SmartContract/Native/ContractMethodMetadata.cs
+17 −1 src/Neo/SmartContract/Native/CryptoLib.cs
+9 −31 src/Neo/SmartContract/Native/FungibleToken.cs
+7 −3 src/Neo/SmartContract/Native/GasToken.cs
+1 −3 src/Neo/SmartContract/Native/LedgerContract.cs
+139 −32 src/Neo/SmartContract/Native/NativeContract.cs
+21 −64 src/Neo/SmartContract/Native/NeoToken.cs
+15 −56 src/Neo/SmartContract/Native/OracleContract.cs
+8 −7 src/Neo/SmartContract/Native/PolicyContract.cs
+4 −27 src/Neo/SmartContract/Native/RoleManagement.cs
+1 −1 src/Neo/SmartContract/Native/StdLib.cs
+10 −0 src/Neo/SmartContract/StorageItem.cs
+90 −0 src/Neo/Wallets/Helper.cs
+1 −88 src/Neo/Wallets/Wallet.cs
+2 −2 tests/Neo.UnitTests/Ledger/UT_MemoryPool.cs
+6 −0 tests/Neo.UnitTests/Persistence/UT_MemoryStore.cs
+151 −0 tests/Neo.UnitTests/SmartContract/Native/UT_ContractEventAttribute.cs
+32 −0 tests/Neo.UnitTests/SmartContract/Native/UT_ContractMethodAttribute.cs
+93 −0 tests/Neo.UnitTests/SmartContract/Native/UT_CryptoLib.cs
+21 −0 tests/Neo.UnitTests/SmartContract/Native/UT_NativeContract.cs
+5 −4 tests/Neo.UnitTests/SmartContract/UT_ApplicationEngineProvider.cs
+3 −3 tests/Neo.UnitTests/SmartContract/UT_InteropService.cs
+3 −3 tests/Neo.UnitTests/SmartContract/UT_JsonSerializer.cs
+8 −1 tests/Neo.UnitTests/TestBlockchain.cs
+127 −0 tests/Neo.UnitTests/UT_ProtocolSettings.cs
+15 −4 tests/Neo.VM.Tests/Types/TestEngine.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ public class Contract_NativeContracts
public void Test_Init()
{
snapshot = new TestDataCache();
genesisBlock = new NeoSystem(TestProtocolSettings.Default, new MemoryStore()).GenesisBlock;
genesisBlock = new NeoSystem(TestProtocolSettings.Default).GenesisBlock;
}

[TestMethod]
Expand Down
2 changes: 1 addition & 1 deletion tests/Neo.Compiler.CSharp.UnitTests/UnitTest_Types.cs
Original file line number Diff line number Diff line change
Expand Up @@ -399,7 +399,7 @@ public void tuple2_Test()
[TestMethod]
public void event_Test()
{
var system = new NeoSystem(TestProtocolSettings.Default, new MemoryStore());
var system = new NeoSystem(TestProtocolSettings.Default);
using var testengine = new TestEngine(verificable: new Transaction()
{
Signers = new Signer[] { new Signer() { Account = UInt160.Parse("0xa400ff00ff00ff00ff00ff00ff00ff00ff00ff01") } },
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ public class ContractTest
[TestInitialize]
public void Init()
{
var system = new NeoSystem(TestProtocolSettings.Default, new MemoryStore());
var system = new NeoSystem(TestProtocolSettings.Default);
_engine = new TestEngine.TestEngine(verificable: new Transaction()
{
Signers = new Signer[] { new Signer() { Account = UInt160.Parse("0xa400ff00ff00ff00ff00ff00ff00ff00ff00ff01") } },
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ public static class TestBlockchain

static TestBlockchain()
{
TheNeoSystem = new NeoSystem(TestProtocolSettings.Default, new MemoryStore());
TheNeoSystem = new NeoSystem(TestProtocolSettings.Default);
}

public static StorageKey CreateStorageKey(this NativeContract contract, byte prefix, ISerializable key = null)
Expand Down
2 changes: 1 addition & 1 deletion tests/Neo.SmartContract.TestEngine/Extensions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ public static void ContractAdd(this DataCache snapshot, ContractState contract)

public static void DeployNativeContracts(this DataCache snapshot, Block? persistingBlock = null)
{
persistingBlock ??= new NeoSystem(TestProtocolSettings.Default, new MemoryStore()).GenesisBlock;
persistingBlock ??= new NeoSystem(TestProtocolSettings.Default).GenesisBlock;

var method = typeof(SmartContract.Native.ContractManagement).GetMethod("OnPersist", System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Instance);
var engine = new TestEngine(TriggerType.OnPersist, null, snapshot, persistingBlock);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public void GenerateNativeArtifacts()
{
foreach (var n in Neo.SmartContract.Native.NativeContract.Contracts)
{
var manifest = n.Manifest;
var manifest = n.GetContractState(ProtocolSettings.Default, uint.MaxValue).Manifest;
var source = manifest.GetArtifactsSource(manifest.Name, generateProperties: true);
var fullPath = Path.GetFullPath($"../../../../../src/Neo.SmartContract.Testing/Native/{manifest.Name}.cs");

Expand Down
Loading