Skip to content

Conversation

@Ederich013
Copy link

Part of #13304

Refactored test cases GetUsageStatisticsActionTest.java to PublishFeedbackSessionActionTest.java (71-78) and StudentCourseJoinEmailWorkerActionTest.java(94).

Details recorded here:
Refactoring_Report.md

Guanglei Cheng and others added 13 commits October 14, 2025 18:00
…CourseJoinEmailWorkerActionTest, and add report md
remove this duplicate record
- Remove trailing whitespaces from PublishFeedbackSessionActionTest.java (lines 72, 82, 91)
- Remove trailing whitespaces from QueryLogsActionTest.java (line 165)
- Fixes Checkstyle RegexpSinglelineJava violations
Add missing mock for getFeedbackSession to fix EntityNotFoundException.
The convenience method requires this mock to be set up for access control verification.
@Ederich013
Copy link
Author

Hi, @InfinityTwo could you kindly review this pr? I checked previous pr #13359 and it seems the E2E test error isn't relevant with refactoring.

@InfinityTwo
Copy link
Contributor

@Ederich013 Thanks for your contribution. However, the error was indeed caused by a refactoring, not by the one you mentioned, but another PR that has been merged (#13357)

At the moment, even if I were to review your PR, I can't merge it since it will still failing checks. However, I'll keep your PR in mind and review it onces the other refactor backlogs have been merged successfully in case of any cascading errors from other merges.

@InfinityTwo
Copy link
Contributor

@Ederich013 Alternatively, you can consider creating a fix based on your report that you made with another PR on the failing checks. If you can successfully fix the issue, I can review it and merge all your PRs

Copy link
Contributor

@InfinityTwo InfinityTwo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Most of the tests LGTM! I have a few comments, but once those are resolved and the E2E issue fixes are merged, I think this is good to go

errorLogTimestamp2, errorLogTextPayload2, errorLogJsonPayLoad2);
}

/**
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The other test files don't have the large chunk of comments here (also ditto on your other files with these large chunks of comments). I see your view in making the code easier to understand, and it's great, but perhaps, would it be better if we could keep the standardisation? If you think comments would help, what do you think of adding it inside BaseActionTest.java instead?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you might have accidentally added this file. In the case where I'm wrong, what do you think of documenting it elsewhere instead?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah it shoud be removed. Will fix those issue after the final exams, likely after 10th Nov.

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.

2 participants