planetarium / libplanet

Blockchain in C#/.NET for on-chain, decentralized gaming
https://docs.libplanet.io/
GNU Lesser General Public License v2.1
505 stars 139 forks source link

Remove redundant `Initialize()` on `TestUtils` #3781

Open OnedgeLee opened 1 month ago

OnedgeLee commented 1 month ago

https://github.com/planetarium/libplanet/blob/f3d6674a59cb00a961e67b68c8090d43de6dbc92/Libplanet.Tests/TestUtils.cs#L429-L442

Action Initialize() updates validator set of IWorld with given parameter validatorSet. So above code, that iterates validatorSet, is redundant. (Initialize() only needs to be called once.)