-
Notifications
You must be signed in to change notification settings - Fork 28
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
304 call mocks are not matching call signatures when one or more program parameters are qualified #308
Conversation
Fixing problem where call mocks can´t find the CALL because the call uses qualified variables. Mock and verify will now find the qualifiers for variables and the arguments can now match CALL´s Signed-off-by: Thomas N. Kramer <[email protected]>
fix, to handle both in and of in a test case Signed-off-by: Thomas N. Kramer <[email protected]>
tests for this cobol check enhancement Signed-off-by: Thomas N. Kramer <[email protected]>
Signed-off-by: Thomas N. Kramer <[email protected]>
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 would like some more tests about the arguments. See the test: call_mock_gets_correct_arguments()
as an example. A test should exist for arguments with one qualified reference and one with multiple THIS IN SOMETHING IN SOMETHING-ELSE IN ...
.
I would also like a test for loading in the arguments from the InterpreterController. See it_sets_possible_mock_args()
as an example.
Otherwise it looks good 😄
src/test/java/org/openmainframeproject/cobolcheck/TestSuiteParserParsingTest.java
Outdated
Show resolved
Hide resolved
param number \ param type | normal | qualified | test name none covered* - Covered* - one covered* - X verify_can_attach_to_call_mock_with_one_qualified_argument X X verify_call_mock_with_qualified_arguments_mixed two covered* - X verify_can_attach_to_call_mock_with_qualified_arguments X X CALL_MOCK_param_is_qualified_two_but_one three covered* - X CALL_MOCK_param_is_qualified_three X X CALL_MOCK_param_three_is_qualified_three_is_not many (5/6) covered* - X CALL_MOCK_param_six_is_qualified X X CALL_MOCK_param_five_is_qualified_six_is_not * (must be) covered by tests already (I have´nt checked) Signed-off-by: Thomas N. Kramer <[email protected]>
tests have been reworked to use the assertThrows approach. Signed-off-by: Thomas N. Kramer <[email protected]>
The file is generated during a test run, and it contains information about the user Signed-off-by: Thomas N. Kramer <[email protected]>
…obol-check into 304-call-mocks-arent-matching-call-signatures-when-one-or-more-program-parameters-are-qualified � Conflicts: � src/main/java/org/openmainframeproject/cobolcheck/services/cobolLogic/Interpreter.java � src/test/cobol/MOCKTEST/MockCallTest.cut
src/main/java/org/openmainframeproject/cobolcheck/features/testSuiteParser/TestSuiteParser.java
Outdated
Show resolved
Hide resolved
src/main/java/org/openmainframeproject/cobolcheck/services/cobolLogic/Interpreter.java
Outdated
Show resolved
Hide resolved
Signed-off-by: Thomas N. Kramer <[email protected]>
Signed-off-by: Thomas N. Kramer <[email protected]>
Signed-off-by: Thomas N. Kramer <[email protected]>
<TestSuiteParser> uses the new class to hold information about the tokens being parsed. The corresponding unit test has been updated. Signed-off-by: Thomas N. Kramer <[email protected]>
The requested changes has been implemented
CALL MOCK and VERIFY CALL will read parameters with qualifiers.
When tests are passed and COBOL is generated, the mocking and verifying is done correctly for CALLs with and without parameters that are written with qualifiers.