-
Notifications
You must be signed in to change notification settings - Fork 3k
Ingela/eqc test cuddling #10287
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
Ingela/eqc test cuddling #10287
Conversation
CT Test Results 2 files 66 suites 26m 38s ⏱️ Results for commit b9b2135. ♻️ This comment has been updated with latest results. To speed up review, make sure that you have read Contributing to Erlang/OTP and that all checks pass. See the TESTING and DEVELOPMENT HowTo guides for details about how to run test locally. Artifacts
// Erlang/OTP Github Action Bot |
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.
Pull Request Overview
Modernizes property-based tests to use Common Test’s ct_property_test and simplifies property assertions and generators.
- Replace per-tool conditional includes with ct_property_test.hrl.
- Switch generators from oneof to elements where selecting from fixed sets.
- Refactor repeated handshake test logic into a helper and simplify boolean assertions.
Reviewed Changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.
File | Description |
---|---|
lib/ssl/test/property_test/ssl_eqc_handshake.erl | Use ct_property_test.hrl; simplify equality check; switch generators to elements for signature schemes. |
lib/ssl/test/property_test/ssl_eqc_ecc.erl | Use ct_property_test.hrl in place of per-tool includes. |
lib/ssl/test/property_test/ssl_eqc_cipher_format.erl | Use ct_property_test.hrl; simplify boolean properties; minor generator/format updates. |
lib/ssl/test/property_test/ssl_eqc_chain.erl | Use ct_property_test.hrl; factor repeated logic into signature_algs_test/2; use elements for generators. |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
_ -> | ||
false | ||
end | ||
tls_handshake:decode_handshake(TLSVersion, Type, Data) == Handshake |
Copilot
AI
Oct 16, 2025
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.
[nitpick] Prefer exact equality (=:=) over == for term comparison to avoid unintended numeric coercion. Here, using =:= makes the intent of structural equivalence explicit.
tls_handshake:decode_handshake(TLSVersion, Type, Data) == Handshake | |
tls_handshake:decode_handshake(TLSVersion, Type, Data) =:= Handshake |
Copilot uses AI. Check for mistakes.
false | ||
end | ||
). | ||
ssl:str_to_suite(ssl:suite_to_str(CipherSuite)) == CipherSuite). |
Copilot
AI
Oct 16, 2025
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.
[nitpick] Use exact equality (=:=) instead of == to compare terms. This ensures strict structural equality and avoids numeric type coercion.
Copilot uses AI. Check for mistakes.
). | ||
?FORALL({CipherSuite, _TLSVersion}, | ||
?LET(Version, pre_tls_1_3_version(), {anon_cipher_suite(Version), Version}), | ||
ssl:str_to_suite(ssl:suite_to_str(CipherSuite)) == CipherSuite |
Copilot
AI
Oct 16, 2025
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.
[nitpick] Use =:= instead of == for exact term equality to make the comparison strict and unambiguous.
ssl:str_to_suite(ssl:suite_to_str(CipherSuite)) == CipherSuite | |
ssl:str_to_suite(ssl:suite_to_str(CipherSuite)) =:= CipherSuite |
Copilot uses AI. Check for mistakes.
Improvement of existing property based tests