Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Migrate tests from the old message_parser to test the message_deserializer class #4166

Conversation

thsfs
Copy link
Contributor

@thsfs thsfs commented Mar 3, 2023

The message_parser class is not used any more and will be removed soon. More tests are needed to the message_deserializer class. This PR covers the support and the integrity of the different message types handled.

Thiago Silva added 8 commits March 2, 2023 22:32
The old test checked the bytes generated the same confirm_ack object by
ensuring its visitor was processed only once. Also verified the
parse_status was success. In the new implementation the visitor isn't
part of the deserializer. The outcome object is compared to the
original, and the parse_status should be success. This is the sanity
test, where the deserialization is expected to happen successfully.

Also checks if the message pointer can be downcast to the proper type,
that is the same of verifying its type is supported.
@thsfs thsfs requested review from clemahieu and dsiganos March 3, 2023 01:57
@thsfs thsfs added the unit test Related to a new, changed or fixed unit test label Mar 3, 2023
@thsfs thsfs merged commit 955c79e into nanocurrency:develop Mar 7, 2023
@thsfs thsfs deleted the message_parser_to_message_deserializer_test_migration branch March 7, 2023 15:49
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
unit test Related to a new, changed or fixed unit test
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants