Skip to content

chore: update tests mod#962

Merged
hwbrzzl merged 1 commit intomasterfrom
bowen/update-tests-mod1
Mar 18, 2025
Merged

chore: update tests mod#962
hwbrzzl merged 1 commit intomasterfrom
bowen/update-tests-mod1

Conversation

@hwbrzzl
Copy link
Contributor

@hwbrzzl hwbrzzl commented Mar 18, 2025

📑 Description

Closes https://github.com/goravel/goravel/issues/

The summary will be generated by Copilot in the below.

✅ Checks

  • Added test cases for my code

Copilot AI review requested due to automatic review settings March 18, 2025 09:52
@hwbrzzl hwbrzzl requested a review from a team as a code owner March 18, 2025 09:52
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 PR updates the tests module by reorganizing grammar interface definitions and removing redundant mock implementations for version compilation.

  • Reorganizes interface definitions in grammar.go to extract common methods into a dedicated CommonGrammar interface.
  • Removes CompileVersion mock implementations from both GormGrammar and SchemaGrammar, requiring corresponding test updates.

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated no comments.

File Description
contracts/database/driver/grammar.go Reorganizes grammar interfaces to consolidate common functionalities into CommonGrammar.
mocks/database/driver/GormGrammar.go Removes the CompileVersion mock functions to align with the new interface design.
mocks/database/driver/SchemaGrammar.go Removes the CompileVersion mock functions to align with the new interface design.
Comments suppressed due to low confidence (2)

mocks/database/driver/GormGrammar.go:162

  • The removal of the CompileVersion mock in GormGrammar may leave tests with uncovered cases. Ensure that tests now verify version compilation via the new CommonGrammar interface.
func (_m *GormGrammar) CompileVersion() string {

mocks/database/driver/SchemaGrammar.go:1468

  • The removal of the CompileVersion mock in SchemaGrammar could result in gaps in test coverage. Verify that tests have been updated to cover version compilation through the CommonGrammar interface.
func (_m *SchemaGrammar) CompileVersion() string {

@codecov
Copy link

codecov bot commented Mar 18, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 69.14%. Comparing base (9dd41c7) to head (027b9be).
Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #962   +/-   ##
=======================================
  Coverage   69.14%   69.14%           
=======================================
  Files         158      158           
  Lines       10607    10607           
=======================================
  Hits         7334     7334           
  Misses       2942     2942           
  Partials      331      331           

☔ 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.

@hwbrzzl hwbrzzl merged commit f437993 into master Mar 18, 2025
13 checks passed
@hwbrzzl hwbrzzl deleted the bowen/update-tests-mod1 branch March 18, 2025 09:57
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.

2 participants