Skip to content

Commit

Permalink
RpcServerSettings.Default with { SessionEnabled = true }
Browse files Browse the repository at this point in the history
  • Loading branch information
Hecate2 committed Aug 17, 2024
1 parent 14d409a commit c3f7f4b
Showing 1 changed file with 1 addition and 22 deletions.
23 changes: 1 addition & 22 deletions tests/Neo.Plugins.RpcServer.Tests/UT_RpcServer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -40,28 +40,7 @@ public void TestSetup()
_memoryStore = new MemoryStore();
_memoryStoreProvider = new TestMemoryStoreProvider(_memoryStore);
_neoSystem = new NeoSystem(TestProtocolSettings.SoleNode, _memoryStoreProvider);
_rpcServer = new RpcServer(_neoSystem, new RpcServerSettings
{
Network = 5195086u,
BindAddress = IPAddress.None,
SslCert = string.Empty,
SslCertPassword = string.Empty,
MaxGasInvoke = (long)new BigDecimal(10M, NativeContract.GAS.Decimals).Value,
MaxFee = (long)new BigDecimal(0.1M, NativeContract.GAS.Decimals).Value,
TrustedAuthorities = Array.Empty<string>(),
EnableCors = true,
AllowOrigins = Array.Empty<string>(),
KeepAliveTimeout = 60,
RequestHeadersTimeout = 15,
MaxIteratorResultItems = 100,
MaxStackSize = ushort.MaxValue,
DisabledMethods = Array.Empty<string>(),
MaxConcurrentConnections = 40,
MaxRequestBodySize = 5 * 1024 * 1024,
SessionEnabled = true,
SessionExpirationTime = TimeSpan.FromSeconds(60),
FindStoragePageSize = 50
});
_rpcServer = new RpcServer(_neoSystem, RpcServerSettings.Default with { SessionEnabled = true });
_walletAccount = _wallet.Import("KxuRSsHgJMb3AMSN6B9P3JHNGMFtxmuimqgR9MmXPcv3CLLfusTd");
var key = new KeyBuilder(NativeContract.GAS.Id, 20).Add(_walletAccount.ScriptHash);
var snapshot = _neoSystem.GetSnapshotCache();
Expand Down

0 comments on commit c3f7f4b

Please sign in to comment.