-
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
Unit test Fail when running UT_Culture and UT_RemoteNode together #922
Comments
I think we have a mailbox issue. I don't understand the changes Erik made to make the mailbox work. Can you disable these tests? |
OK, let's disable them first. |
I'll try to understand this too, it's fundamental for my understanding of other Akka/TestKit features.. this is supposed to work properly. 🤔 |
@igormcoelho Maybe we should reset the akka system during test initialization? Not sure, I think it is something with the mailbox, I can't be sure. |
We need to understand the real cause first.
Perhaps we need to change a few things on the code, perhaps controlling this string in a single place is enough to avoid problems. Let's see. |
Looks like it's building Connection twice 🤔
|
@igormcoelho do you think this may be evidence that we have duplicated messages? Can you check? I'm using my mac right now, I can't run tests 😞 |
Looks like inspecting from ...Any(p => p.Remote.Address.Equals(Remote.Address) && p.Version?.Nonce == version.Nonce)) Seems connected to this issue:
Bad execution:
By simply inspecting on Remote.Address, all tests break now (DifferentMagic would never check it, that's why they pass..). In fact, var remoteNodeActor = ActorOfAsTestActorRef(() => new RemoteNode(testBlockchain, connectionTestProbe, null, null)); These null cannot exist. |
@igormcoelho but I still don't understand why this caused the side effects, but I trust you when you say it is the test. Why does it use to work? |
I'm nearly fixing it in fact... another issue now is that: LocalNode.Singleton.RemoteNodes.Values.Where(p => p != this) is not cutting itself I guess... ======== I think I discovered the reason (another issue, besides the null). When you run multiple tests, you record a new RemoteNode on |
i receive this one
From this |
We need that |
after this weekend I think I can propose a good solution for this, definitive one. Now that the cause is understood... |
please review this until that #936 |
@igormcoelho, can you please come back with a good solution that has a strategical design? |
I fully agree, just should be properly fixed, not just workarounds, one after another. This affects all tests involving blockchain test module, for all other modules. |
We encountered a strange bug. We were able to successfully run all the unit tests yesterday, but today unit test result is failed when running
UT_RemoteNode
andUT_Culture
together on some computers (and some other computers can run successfully). Recently this part of code seems to have not been modified. The problem is akka error.When running
RemoteNode_Test_Accept_IfSameMagic
method alone, the result is success.When running
All_Tests_Cultures
method alone, the result is failed.The text was updated successfully, but these errors were encountered: