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

Improve ODK-X Services Test Coverage:Write Tests for logging class in the Application package #511

Open
Agaba-derrick opened this issue Oct 19, 2024 · 0 comments

Comments

@Agaba-derrick
Copy link

This issue involves adding unit tests for the WebLoggerImpl and WebLoggerAppNameUnknownImpl classes in the org.opendatakit.logging package.
The tests should validate logging functionality and file handling,

Tests to Cover:

  • Logging Methods:
  • Verify that all logging methods (a, t, v, d, i, w, e, s) call the log() method correctly.
  • Log File Handling:
  • Test the close() method to ensure it behaves correctly when the log file is open or when the logging directory does not exist.
  • Stale File Scanning:
  • Confirm that staleFileScan() correctly deletes stale log files older than 30 days and handles directory issues.
  • Log Level Management:
  • Test setMinimumSystemLogLevel() and getMinimumSystemLogLevel() for correct behavior and remapping of SUCCESS and TIP.
  • Exception Logging:
  • Validate that printStackTrace() logs exceptions and formats them correctly.
    Write Unit Test for Uncovered Classes in ODK-X AndroidLibrary #507
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

No branches or pull requests

1 participant