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

Remove tools and dev tools AngularJS controllers #6544

Merged
merged 8 commits into from Apr 4, 2024

Conversation

Desvelao
Copy link
Member

@Desvelao Desvelao commented Mar 21, 2024

Description

This pull request removes the tools and dev tools AngularJS controllers.

Changes:

  • Remove dev tools and tools controllers
  • Replace the render using an AngularJS template by a ReactJS component
  • Create ToolsRouter component to manage the routing of Dev Tools and
    Ruleset Test views
  • Move logic and render of dev tools to a ReactJS component
  • Remove unused definitions of controllers and variables in AngularJS

Issues Resolved

#6539

Evidence

image
image

Test

Legend:
⚫: none
🟢: pass
🟡: warning
🔴: fail
⚪: not applicable

UI

Test Chrome Firefox Safari
Go to Server management > Dev Tools and the application should be visible
In Server management > Dev Tools, test the API endpoint suggestions are working as previously
In Server management > Dev Tools, run API requests, the response should be displayed in the reghit side
In Server management > Dev Tools, click on the button to get more information about the current API endpoint in the editor of the left side
In Server management > Dev Tools, click on the link to get information about the API referene that is located in the top right corner
In Server management > Dev Tools, click on the button to export the output of API request to JSON. Verify the file content has the same content that was displayed in the output view when this was exported
Go to Server management > Dev Tools and the breadcrumb should display the name of the application
Go to Server management > Ruleset Test and the application should be visible
Go to Server management > Ruleset Test and the breadcrumb should display the name of the application

Details

⚫ Go to Server management > Dev Tools and the application should be visible

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ In Server management > Dev Tools, test the API endpoint suggestions are working as previously

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ In Server management > Dev Tools, run API requests, the response should be displayed in the reghit side

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ In Server management > Dev Tools, click on the button to get more information about the current API endpoint in the editor of the left side

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ In Server management > Dev Tools, click on the link to get information about the API referene that is located in the top right corner

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ In Server management > Dev Tools, click on the button to export the output of API request to JSON. Verify the file content has the same content that was displayed in the output view when this was exported

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Go to Server management > Dev Tools and the breadcrumb should display the name of the application

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Go to Server management > Ruleset Test and the application should be visible

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

⚫ Go to Server management > Ruleset Test and the breadcrumb should display the name of the application

Chrome - ⚫

Firefox - ⚫

Safari - ⚫

Check List

  • All tests pass
    • yarn test:jest
  • New functionality includes testing.
  • New functionality has been documented.
  • Update CHANGELOG.md
  • Commits are signed per the DCO using --signoff

- Remove dev tools and tools controllers
- Replace the render using an AngularJS template by a ReactJS component
- Create ToolsRouter component to manage the routing of Dev Tools and
  Ruleset Test views
- Move logic and render of dev tools to a ReactJS component
- Remove unused definitions of controllers and variables in AngularJS
@Desvelao Desvelao self-assigned this Mar 21, 2024
…o feat/6536-remove-angularjs-controller-tools
@Desvelao Desvelao linked an issue Mar 21, 2024 that may be closed by this pull request
@Desvelao Desvelao marked this pull request as ready for review March 21, 2024 13:04
@JuanGarriuz JuanGarriuz self-requested a review April 2, 2024 11:46
@JuanGarriuz
Copy link
Member

JuanGarriuz commented Apr 3, 2024

Test

Legend:
⚫: none
🟢: pass
🟡: warning
🔴: fail
⚪: not applicable

UI

Test Chrome Firefox Safari
Go to Server management > Dev Tools and the application should be visible 🟢
In Server management > Dev Tools, test the API endpoint suggestions are working as previously 🟢
In Server management > Dev Tools, run API requests, the response should be displayed in the reghit side 🟢
In Server management > Dev Tools, click on the button to get more information about the current API endpoint in the editor of the left side 🟢
In Server management > Dev Tools, click on the link to get information about the API referene that is located in the top right corner 🟢
In Server management > Dev Tools, click on the button to export the output of API request to JSON. Verify the file content has the same content that was displayed in the output view when this was exported 🟢
Go to Server management > Dev Tools and the breadcrumb should display the name of the application 🟢
Go to Server management > Ruleset Test and the application should be visible 🟢
Go to Server management > Ruleset Test and the breadcrumb should display the name of the application 🟢

Details

🟢 Go to Server management > Dev Tools and the application should be visible

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 In Server management > Dev Tools, test the API endpoint suggestions are working as previously

Chrome - 🟢
image
image
image
image

Firefox - ⚫

Safari - ⚫

🟢 In Server management > Dev Tools, run API requests, the response should be displayed in the reghit side

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 In Server management > Dev Tools, click on the button to get more information about the current API endpoint in the editor of the left side

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 In Server management > Dev Tools, click on the link to get information about the API reference that is located in the top right corner

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 In Server management > Dev Tools, click on the button to export the output of API request to JSON. Verify the file content has the same content that was displayed in the output view when this was exported

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Go to Server management > Dev Tools and the breadcrumb should display the name of the application

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Go to Server management > Ruleset Test and the application should be visible

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

🟢 Go to Server management > Ruleset Test and the breadcrumb should display the name of the application

Chrome - 🟢
image

Firefox - ⚫

Safari - ⚫

JuanGarriuz
JuanGarriuz previously approved these changes Apr 3, 2024
Copy link
Member

@JuanGarriuz JuanGarriuz left a comment

Choose a reason for hiding this comment

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

LGTM!!

@yenienserrano yenienserrano self-requested a review April 3, 2024 11:32
@yenienserrano
Copy link
Member

yenienserrano commented Apr 3, 2024

Test Chrome Firefox Safari
Go to Server management > Dev Tools and the application should be visible 🟢
In Server management > Dev Tools, test the API endpoint suggestions are working as previously 🟢
In Server management > Dev Tools, run API requests, the response should be displayed in the reghit side 🟢
In Server management > Dev Tools, click on the button to get more information about the current API endpoint in the editor of the left side 🟡
In Server management > Dev Tools, click on the link to get information about the API referene that is located in the top right corner 🟡
In Server management > Dev Tools, click on the button to export the output of API request to JSON. Verify the file content has the same content that was displayed in the output view when this was exported 🟢
Go to Server management > Dev Tools and the breadcrumb should display the name of the application 🟢
Go to Server management > Ruleset Test and the application should be visible 🟢
Go to Server management > Ruleset Test and the breadcrumb should display the name of the application 🟢

Details

🟢 Go to Server management > Dev Tools and the application should be visible

Chrome - ⚫

Firefox - ⚫

Safari - 🟢

image
🟢 In Server management > Dev Tools, test the API endpoint suggestions are working as previously

Chrome - ⚫

Firefox - ⚫

Safari - 🟢

image
🟢 In Server management > Dev Tools, run API requests, the response should be displayed in the reghit side

Chrome - ⚫

Firefox - ⚫

Safari - 🟢

image
🟡 In Server management > Dev Tools, click on the button to get more information about the current API endpoint in the editor of the left side

When I click on the information icons, the text area on the left changes position

Chrome - ⚫

Firefox - ⚫

Safari - 🟡

image
🟡 In Server management > Dev Tools, click on the link to get information about the API referene that is located in the top right corner

When I click on the information icons, the text area on the left changes position

Chrome - ⚫

Firefox - ⚫

Safari - 🟡

image
🟢 In Server management > Dev Tools, click on the button to export the output of API request to JSON. Verify the file content has the same content that was displayed in the output view when this was exported

Chrome - ⚫

Firefox - ⚫

Safari - 🟢

image image
🟢 Go to Server management > Dev Tools and the breadcrumb should display the name of the application

Chrome - ⚫

Firefox - ⚫

Safari - 🟢

image
🟢 Go to Server management > Ruleset Test and the application should be visible

Chrome - ⚫

Firefox - ⚫

Safari - 🟢

image
🟢 Go to Server management > Ruleset Test and the breadcrumb should display the name of the application

Chrome - ⚫

Firefox - ⚫

Safari - 🟢

image

yenienserrano
yenienserrano previously approved these changes Apr 3, 2024
Copy link
Member

@yenienserrano yenienserrano left a comment

Choose a reason for hiding this comment

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

CR: ✅
Test: ✅

Copy link
Contributor

github-actions bot commented Apr 4, 2024

Wazuh Core plugin code coverage (Jest) test % values
Statements 31.12% ( 286 / 919 )
Branches 29.88% ( 107 / 358 )
Functions 28.1% ( 86 / 306 )
Lines 30.71% ( 278 / 905 )

Copy link
Contributor

github-actions bot commented Apr 4, 2024

Wazuh Check Updates plugin code coverage (Jest) test % values
Statements 76.44% ( 172 / 225 )
Branches 58.65% ( 61 / 104 )
Functions 61.7% ( 29 / 47 )
Lines 76.44% ( 172 / 225 )

Copy link
Contributor

github-actions bot commented Apr 4, 2024

Main plugin code coverage (Jest) test % values
Statements 10.64% ( 3685 / 34601 )
Branches 7.14% ( 1621 / 22699 )
Functions 10.31% ( 849 / 8234 )
Lines 10.79% ( 3581 / 33165 )

@asteriscos asteriscos merged commit ee9894d into 4.9.0 Apr 4, 2024
4 checks passed
@asteriscos asteriscos deleted the feat/6536-remove-angularjs-controller-tools branch April 4, 2024 09:37
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.

[Remove discover] Refactor AngularJS tools and dev tools controllers
4 participants