Skip to content
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

AisMessage::getEncoded is largely untested #38

Open
Zoybean opened this issue Aug 7, 2018 · 2 comments
Open

AisMessage::getEncoded is largely untested #38

Zoybean opened this issue Aug 7, 2018 · 2 comments

Comments

@Zoybean
Copy link

Zoybean commented Aug 7, 2018

The test suite does not cover the getEncoded method of most messages, and the tests which call that method are heavily obfuscated, making it unclear what messages are being tested without debugging the tests as they run.
During debugging, aisDecodeEncode only tested getEncoded in messages 1, 3, 4, 5, and 24 (assuming the changes in #37), and the rest of EncodeTest only covered getEncoded in the above messages and message 12. Overall, only messages 1, 3, 4, 5, 6, 8, 12, 18, and 24 had their getEncoded methods called in any test methods.

@tbsalling
Copy link
Contributor

Hi @Zoybean - thanks; your contribution is welcomed.

It would be a great help if you could send me a pull request with the changes you propose.

Thanks,
/Thomas.

@Zoybean
Copy link
Author

Zoybean commented Aug 20, 2018

I would attempt to write a test covering this class, however as I mentioned the existing tests are heavily obfuscated and hardly documented, and as such I am unsure of how to make a test string to test a specific message. See decode_encode_messages.txt for an example of the test strings I would need to add to.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants