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

implemented unit testing of log package #1234

Closed
wants to merge 2 commits into from

Conversation

harshitghagre
Copy link

@harshitghagre harshitghagre commented Feb 11, 2025

What type of PR is this?
This is a test/unit PR that adds unit tests for the logging functionality.

What this PR does / why we need it:
This PR implements unit tests for the logs package, ensuring that the logging functionality behaves as expected. Unit tests are crucial for catching regressions and maintaining code quality, especially for critical components like logging.

Which issue(s) this PR fixes:
Fixes #1226 (Implement log unit tests).

Special notes for your reviewer:

  • Mocked the Kmesh daemon API for testing.
  • Covered edge cases like invalid logger names and levels.
  • Tested both GetLoggerNames and SetLoggerLevel functions.

Does this PR introduce a user-facing change?:
No, this PR does not introduce any user-facing changes.

@kmesh-bot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign supercharge-xsy for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@kmesh-bot
Copy link
Collaborator

Welcome @harshitghagre! It looks like this is your first PR to kmesh-net/kmesh 🎉

@YaoZengzeng
Copy link
Member

@harshitghagre First of all, thanks for your contribution!

I guess this PR and #1226 implement same function?

I think you could do something hasn't assigned yet, like E2E for log?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants