Skip to content

Added ForceStaticMockListener to run "configure mockito-inline" action. #438

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

Merged
merged 1 commit into from
Jul 7, 2022

Conversation

nikitavlaev
Copy link
Member

@nikitavlaev nikitavlaev commented Jul 6, 2022

Description

Added ForceStaticMockListener to run "configure mockito-inline" action.
Refactored url listener in notifications to support callbacks (to encapsulate GenerateTestsDialogWindow).

Fixes #447

Type of Change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)

How Has This Been Tested?

Automated Testing

Not applicable.

Manual Scenario

  1. Create setup like in the issue.
  2. Run tests without static mocking.
  3. No tests with static mocking should be generated.
    Warning with link to an action with "configure mockito-inline" must be available.
  4. Click on the link, OK.
    Mockito-inline must be installed.
  5. Generate tests once again.
    Tests with static mocks should be generated.
    Run tests, no errors must be shown.

Checklist (remove irrelevant options):

  • The change followed the style guidelines of the UTBot project
  • Self-review of the code is passed
  • The change contains enough commentaries, particularly in hard-to-understand areas
  • New documentation is provided or existed one is altered
  • No new warnings

@nikitavlaev nikitavlaev requested a review from EgorkaKulikov July 6, 2022 12:38
@nikitavlaev nikitavlaev self-assigned this Jul 6, 2022
Copy link
Collaborator

@EgorkaKulikov EgorkaKulikov left a comment

Choose a reason for hiding this comment

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

Have several minor points to discussion, sent them to Nikita.
Approve changes anyway as we should merge this changes to main as soon as possible.

@dtim dtim self-requested a review July 7, 2022 07:14
@nikitavlaev nikitavlaev force-pushed the nikitavlaev/force-static-mock-npe branch from 7911545 to 916623c Compare July 7, 2022 07:51
Copy link
Collaborator

@dtim dtim left a comment

Choose a reason for hiding this comment

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

LGTM

@nikitavlaev nikitavlaev force-pushed the nikitavlaev/force-static-mock-npe branch from 916623c to 0ee36a1 Compare July 7, 2022 08:34
@nikitavlaev nikitavlaev enabled auto-merge (rebase) July 7, 2022 08:35
@nikitavlaev nikitavlaev merged commit acc2fff into main Jul 7, 2022
@nikitavlaev nikitavlaev deleted the nikitavlaev/force-static-mock-npe branch July 7, 2022 10:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

NullPointerException in runtime for Random without static mocking
3 participants