Skip to content

feat: [#760] package:uninstall support uninstall goravel/framework facades#1173

Merged
hwbrzzl merged 5 commits intomasterfrom
bowen/#760
Aug 26, 2025
Merged

feat: [#760] package:uninstall support uninstall goravel/framework facades#1173
hwbrzzl merged 5 commits intomasterfrom
bowen/#760

Conversation

@hwbrzzl
Copy link
Contributor

@hwbrzzl hwbrzzl commented Aug 24, 2025

📑 Description

Closes goravel/goravel#760

This pull request refactors package and facade installation and uninstallation logic to improve clarity, error handling, and testability. The changes include updating command constructors to accept more contextual information, switching from direct console output to context-based messaging, and enhancing facade dependency management. Additionally, tests have been updated to reflect these changes and ensure proper behavior.

./artisan package:uninstall Auth Cache
image

✅ Checks

  • Added test cases for my code

@codecov
Copy link

codecov bot commented Aug 24, 2025

Codecov Report

❌ Patch coverage is 79.27928% with 23 lines in your changes missing coverage. Please review.
✅ Project coverage is 68.61%. Comparing base (ff97cb0) to head (bd0ed2e).
⚠️ Report is 2 commits behind head on master.

Files with missing lines Patch % Lines
foundation/console/package_uninstall_command.go 72.15% 16 Missing and 6 partials ⚠️
foundation/application.go 94.73% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1173      +/-   ##
==========================================
+ Coverage   68.52%   68.61%   +0.09%     
==========================================
  Files         225      225              
  Lines       14600    14684      +84     
==========================================
+ Hits        10004    10075      +71     
- Misses       4218     4222       +4     
- Partials      378      387       +9     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

⚠️ Performance Alert ⚠️

Possible performance regression was detected for benchmark.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold 1.50.

Benchmark suite Current: 3f84a47 Previous: 7e25ea1 Ratio
Benchmark_Fatal 4e-7 ns/op 0 B/op 0 allocs/op 2e-7 ns/op 0 B/op 0 allocs/op 2
Benchmark_Fatal - ns/op 4e-7 ns/op 2e-7 ns/op 2

This comment was automatically generated by workflow using github-action-benchmark.

@hwbrzzl hwbrzzl marked this pull request as ready for review August 26, 2025 04:15
Copilot AI review requested due to automatic review settings August 26, 2025 04:15
@hwbrzzl hwbrzzl requested a review from a team as a code owner August 26, 2025 04:15
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This pull request adds support for uninstalling Goravel framework facades through the package:uninstall command. The implementation enhances the existing package uninstallation functionality to handle both packages and facades, with proper dependency management and user confirmation for cascade uninstalls.

Key changes:

  • Extended package:uninstall command to support facade uninstallation with dependency resolution
  • Refactored error handling from direct console output to context-based messaging
  • Added comprehensive test coverage for new facade uninstallation scenarios

Reviewed Changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
foundation/console/package_uninstall_command.go Added facade uninstallation logic with dependency management and confirmation prompts
foundation/console/package_uninstall_command_test.go Enhanced test suite with facade uninstallation scenarios and updated mocking approach
foundation/console/package_install_command.go Refactored error handling to use context methods and extracted helper function
foundation/console/package_install_command_test.go Updated tests to use context-based assertions instead of color output capture
foundation/application.go Added method to detect installed facades by analyzing service providers
foundation/application_test.go Added test coverage for the new installed facades detection functionality

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@hwbrzzl hwbrzzl merged commit 5249efe into master Aug 26, 2025
16 checks passed
@hwbrzzl hwbrzzl deleted the bowen/#760 branch August 26, 2025 07:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

package:uninstall support uninstall goravel/framework facades

2 participants