Skip to content

Commit

Permalink
Reformat and cleanup code and rename AElf.sln to AElf.All.sln
Browse files Browse the repository at this point in the history
  • Loading branch information
eanzhao committed Jun 6, 2022
1 parent 41e76a8 commit 8d5c4b2
Show file tree
Hide file tree
Showing 1,995 changed files with 131,342 additions and 131,997 deletions.
4 changes: 4 additions & 0 deletions .idea/.idea.AElf.All/.idea/encodings.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions .idea/.idea.AElf.All/.idea/indexLayout.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions .idea/.idea.AElf.All/.idea/projectSettingsUpdater.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions .idea/.idea.AElf.All/.idea/vcs.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2,120 changes: 2,120 additions & 0 deletions .idea/.idea.AElf.All/.idea/workspace.xml

Large diffs are not rendered by default.

13 changes: 13 additions & 0 deletions .idea/.idea.AElf.Contracts/.idea/.gitignore

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions .idea/.idea.AElf.Contracts/.idea/.name

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions .idea/.idea.AElf.Contracts/.idea/encodings.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions .idea/.idea.AElf.Contracts/.idea/indexLayout.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions .idea/.idea.AElf.Contracts/.idea/vcs.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions .idea/.idea.all/.idea/.name

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions .idea/.idea.all/.idea/encodings.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions .idea/.idea.all/.idea/indexLayout.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions .idea/.idea.all/.idea/projectSettingsUpdater.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions .idea/.idea.all/.idea/vcs.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2,113 changes: 2,113 additions & 0 deletions .idea/.idea.all/.idea/workspace.xml

Large diffs are not rendered by default.

1,256 changes: 1,256 additions & 0 deletions AElf.All.sln

Large diffs are not rendered by default.

14 changes: 14 additions & 0 deletions AElf.Contracts.sln
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@

Microsoft Visual Studio Solution File, Format Version 12.00
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "contract", "contract", "{651F0F6E-86CF-42D2-9110-5F3EAE5704F0}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "test", "test", "{26990847-E0A2-4FCC-8C71-267CA77557CD}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{51CE1A9E-63A0-49C6-B820-C8519C94F389}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
EndGlobal
1,520 changes: 334 additions & 1,186 deletions AElf.sln

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions AElf.sln.DotSettings
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
<wpf:ResourceDictionary xml:space="preserve" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:s="clr-namespace:System;assembly=mscorlib" xmlns:ss="urn:shemas-jetbrains-com:settings-storage-xaml" xmlns:wpf="http://schemas.microsoft.com/winfx/2006/xaml/presentation">
<s:Boolean x:Key="/Default/CodeEditing/SuppressNullableWarningFix/Enabled/@EntryValue">False</s:Boolean>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=JS/@EntryIndexedValue">JS</s:String>
<s:Boolean x:Key="/Default/UserDictionary/Words/=aelf/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=appsettings/@EntryIndexedValue">True</s:Boolean>
Expand Down
4 changes: 2 additions & 2 deletions Directory.Build.props
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0"?>
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="src\AElf.ContractDeployer\AElf.ContractDeployer.targets" />
<Import Project="AElf.ContractTools.targets" />
<Import Project="src\AElf.ContractDeployer\AElf.ContractDeployer.targets"/>
<Import Project="AElf.ContractTools.targets"/>
</Project>
6 changes: 3 additions & 3 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
- task: UseDotNet@2
displayName: 'Install .NET Core SDK'
inputs:
version: 6.0.5
version: 6.0.x
- script: choco install protoc --version=3.19.4 -y
displayName: 'Install protobuf'
- script: choco install unzip
Expand Down Expand Up @@ -47,7 +47,7 @@ jobs:
- task: UseDotNet@2
displayName: 'Install .NET Core SDK'
inputs:
version: 6.0.5
version: 6.0.x
- script: bash scripts/install_protobuf.sh
- script: bash scripts/download_binary.sh
- script: bash build.sh -target=Test-with-Codecov-N --parts=3 --n=2
Expand Down Expand Up @@ -80,7 +80,7 @@ jobs:
- task: UseDotNet@2
displayName: 'Install .NET Core SDK'
inputs:
version: 6.0.5
version: 6.0.x
- script: bash scripts/install_protobuf.sh
- script: bash scripts/download_binary.sh
- script: bash build.sh -target=Test-with-Codecov-N --parts=3 --n=3
Expand Down
4 changes: 2 additions & 2 deletions bench/AElf.BenchBase/AElf.BenchBase.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Pro.NBench.xUnit" Version="2.0.0" />
<PackageReference Include="Pro.NBench.xUnit" Version="2.0.0"/>
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\..\test\AElf.TestBase\AElf.TestBase.csproj" />
<ProjectReference Include="..\..\test\AElf.TestBase\AElf.TestBase.csproj"/>
</ItemGroup>

</Project>
2 changes: 1 addition & 1 deletion bench/AElf.BenchBase/Assembly.cs
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
using Xunit;

[assembly: CollectionBehavior(DisableTestParallelization = true)]
[assembly: CollectionBehavior(DisableTestParallelization = true)]
27 changes: 12 additions & 15 deletions bench/AElf.BenchBase/BenchBaseAElfModule.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,18 @@
using AElf.TestBase;
using Volo.Abp.Modularity;

namespace AElf.BenchBase
namespace AElf.BenchBase;

[DependsOn(typeof(TestBaseAElfModule))]
public class BenchBaseAElfModule : AElfModule
{
}

public class BenchBaseTest<TModule> : AElfIntegratedTest<TModule>
where TModule : IAbpModule
{
[DependsOn(typeof(TestBaseAElfModule))]
public class BenchBaseAElfModule : AElfModule
{

}

public class BenchBaseTest<TModule> : AElfIntegratedTest<TModule>
where TModule: IAbpModule
{
}
}

public class BenchBaseTest : AElfIntegratedTest<TestBaseAElfModule>
{

}
public class BenchBaseTest : AElfIntegratedTest<TestBaseAElfModule>
{
}
Original file line number Diff line number Diff line change
@@ -1,43 +1,40 @@
using System;
using Google.Protobuf.WellKnownTypes;

namespace AElf.Benchmark.PerformanceTestContract
namespace AElf.Benchmark.PerformanceTestContract;

public class PerformanceTestContract : PerformanceTestContractContainer.PerformanceTestContractBase
{
public class PerformanceTestContract : PerformanceTestContractContainer.PerformanceTestContractBase
public override UInt64Value Fibonacci(UInt64Value input)
{
public override UInt64Value Fibonacci(UInt64Value input)
{
var result = CalculateFibonacci(input.Value);
return new UInt64Value {Value = result};
}
var result = CalculateFibonacci(input.Value);
return new UInt64Value { Value = result };
}

private ulong CalculateFibonacci(ulong n)
{
if (n == 0 || n == 1)
return n;
return CalculateFibonacci(n - 1) + CalculateFibonacci(n - 2);
}
private ulong CalculateFibonacci(ulong n)
{
if (n == 0 || n == 1)
return n;
return CalculateFibonacci(n - 1) + CalculateFibonacci(n - 2);
}

public override Int32Value LoopExpNop(PerformanceTesteInput input)
public override Int32Value LoopExpNop(PerformanceTesteInput input)
{
for (uint i = 0; i < input.N; i++)
{
for (uint i = 0; i < input.N; i++)
{

}

return new Int32Value {Value = input.Seed};
}

public override DoubleValue LoopDivAdd(DivAddTestInput input)
{
var r = input.X;
for (uint i = 0; i < input.N; i++)
{
r /= input.Y;
r += input.K;
}
return new Int32Value { Value = input.Seed };
}

return new DoubleValue {Value = r};
public override DoubleValue LoopDivAdd(DivAddTestInput input)
{
var r = input.X;
for (uint i = 0; i < input.N; i++)
{
r /= input.Y;
r += input.K;
}

return new DoubleValue { Value = r };
}
}
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
using AElf.Sdk.CSharp.State;

namespace AElf.Benchmark.PerformanceTestContract
namespace AElf.Benchmark.PerformanceTestContract;

public class PerformanceTestContractState : ContractState
{
public class PerformanceTestContractState: ContractState
{

}
}
14 changes: 7 additions & 7 deletions bench/AElf.Benchmark/AElf.Benchmark.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,22 @@
<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<IsPackable>false</IsPackable>
<!-- <NoWarn>0436</NoWarn>-->
<!-- <NoWarn>0436</NoWarn>-->
<OutputType>Exe</OutputType>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="BenchmarkDotNet" Version="0.12.1" />
<PackageReference Include="BenchmarkDotNet.Diagnostics.Windows" Version="0.12.1" />
<PackageReference Include="BenchmarkDotNet" Version="0.12.1"/>
<PackageReference Include="BenchmarkDotNet.Diagnostics.Windows" Version="0.12.1"/>
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\..\test\AElf.OS.Core.Tests\AElf.OS.Core.Tests.csproj" />
<ProjectReference Include="..\..\src\AElf.Kernel.SmartContract.Parallel\AElf.Kernel.SmartContract.Parallel.csproj" />
<ProjectReference Include="..\AElf.Benchmark.PerformanceTestContract\AElf.Benchmark.PerformanceTestContract.csproj" />
<ProjectReference Include="..\..\test\AElf.OS.Core.Tests\AElf.OS.Core.Tests.csproj"/>
<ProjectReference Include="..\..\src\AElf.Kernel.SmartContract.Parallel\AElf.Kernel.SmartContract.Parallel.csproj"/>
<ProjectReference Include="..\AElf.Benchmark.PerformanceTestContract\AElf.Benchmark.PerformanceTestContract.csproj"/>
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\contract\AElf.Contracts.Genesis\AElf.Contracts.Genesis.csproj" />
<ProjectReference Include="..\..\contract\AElf.Contracts.Genesis\AElf.Contracts.Genesis.csproj"/>
<ProjectReference Include="..\..\contract\AElf.Contracts.Consensus.AEDPoS\AElf.Contracts.Consensus.AEDPoS.csproj">
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
<OutputItemType>Contract</OutputItemType>
Expand Down
Loading

0 comments on commit 8d5c4b2

Please sign in to comment.