-
Notifications
You must be signed in to change notification settings - Fork 1k
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
[Neo Plugin UT] Add a dbft unit test system #3371
base: master
Are you sure you want to change the base?
Conversation
@@ -38,6 +38,14 @@ public DBFTPlugin() | |||
RemoteNode.MessageReceived += ((IMessageReceivedHandler)this).RemoteNode_MessageReceived_Handler; | |||
} | |||
|
|||
#if DEBUG |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if debug?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I understand the test but this is a little different from what we had before.
The AkkaTestkit was used to simulate the calls.
Consensus tests need to be something that we can call the same methods and flow of the consensus, such as Reset, InitializeConsensus, MakePrepare Request,etc...
Maybe your way is even better, but this is not clear to me yet.
So, for now I would prefer to merge in another branch until we extend the tests for at least a simple flow of the consensus. Then, we add other possible scenarios.
I will keep updating according to your suggestion, not necessarily be one way, i will also add the method you mentioned. |
Great, let me know because I am available to help as soon as I understand the way you are designing for calling these methods. |
Description
DBFT plugin lacks unit test system. Thus having this pr that build a unit test environment for DBFT plugin.
This UT will mock a 7 nodes network.
Problem still exist in this test engine that consensus will still go automatically, we need a manual system where every single nodes operation can be manually controlled and set. But it should be fine since test is not likly run over 15s.
Fixes # #3231
Type of change
How Has This Been Tested?
Test Configuration:
Checklist: