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

Change the code templates of catch block in tests. #466

Conversation

fedejeanne
Copy link
Contributor

@fedejeanne fedejeanne commented May 26, 2023

Requested by @iloveeclipse in this comment of PR #465

This PR doesn't add any new templates, it merely removes existing overrides of the mentioned template letting them fall back to the default template.

Before (custom template)

try {
	...
} catch (Exception e) {
	fail("4.99", e);
}

After (default template)

try {
	...
} catch (Exception e) {
        //TODO Auto-generated catch block
	e.printStackTrace();
}

@fedejeanne fedejeanne force-pushed the improvements/change_catch_template_tests branch 2 times, most recently from 6538237 to 852d78a Compare May 26, 2023 12:25
@fedejeanne fedejeanne marked this pull request as ready for review May 26, 2023 12:26
@github-actions
Copy link
Contributor

github-actions bot commented May 26, 2023

Test Results

     30 files  ±0       30 suites  ±0   48m 42s ⏱️ + 2m 16s
2 380 tests ±0  2 379 ✔️ ±0  1 💤 ±0  0 ±0 
7 143 runs  ±0  7 139 ✔️ ±0  4 💤 ±0  0 ±0 

Results for commit 2782577. ± Comparison against base commit 160e6ec.

♻️ This comment has been updated with latest results.

@fedejeanne fedejeanne force-pushed the improvements/change_catch_template_tests branch 2 times, most recently from f555602 to 8317bff Compare May 31, 2023 14:23
@fedejeanne
Copy link
Contributor Author

@iloveeclipse I had misinterpreted your comment in the PR before. I changed the templates and also the description of this PR.

I hope I got it right this time? :)

@fedejeanne
Copy link
Contributor Author

Random test failure documented in #472

@mickaelistria mickaelistria added this to the 4.29 M1 milestone Jun 1, 2023
@fedejeanne fedejeanne force-pushed the improvements/change_catch_template_tests branch 2 times, most recently from 5a6861f to 2872537 Compare June 21, 2023 08:32
Remove unnecessary/wrong overrides of the template. "Unnecessary" means
those which set the exact same value as the default value. "Wrong" means
all those which changed the template to generate this code:
fail("4.99",e);
@fedejeanne fedejeanne force-pushed the improvements/change_catch_template_tests branch from 2872537 to 2782577 Compare June 21, 2023 08:37
@fedejeanne
Copy link
Contributor Author

Conflicts have been resolved.

@vogella vogella merged commit d444af5 into eclipse-platform:master Jun 21, 2023
12 checks passed
@fedejeanne fedejeanne deleted the improvements/change_catch_template_tests branch June 21, 2023 09:40
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

Successfully merging this pull request may close these issues.

3 participants