• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

l50 / goutils / 7422663882
88%

Build:
DEFAULT BRANCH: main
Ran 05 Jan 2024 01:58PM UTC
Jobs 1
Files 22
Run time 3s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

05 Jan 2024 01:54PM UTC coverage: 67.492% (-0.5%) from 68.024%
7422663882

push

github

web-flow
Enhance Logging and Pre-Commit Hooks (#545)

Implemented Close Method for Loggers and Enhanced Logging System

**Added:**
- `Close` method in ColorLogger and PlainLogger for effective log file handling.
- Logger interface extended with `Close` method.
- Examples and tests updated to include `Close` method.

**Changed:**
- Adjusted `ConfigureLogger` to align with new `Close` method.
- Minor readability enhancement in `logutils.go`.
- Refactored `ColorLogger` to use static color settings.
- Improved PrettyHandler tests for no color codes in output.
- Updated test messages to include ANSI color codes.
- Refined output validation in PrettyHandler tests.
- Enhanced `run-go-tests.sh` and `go-vet.sh` scripts for performance.
- Moved `CreateLogFile()` and `ConfigureLogger()` to `LogConfig` struct.
- Updated `README.md` and code comments for new logging structure.
- Modified ColorLogger methods for direct slog.Record use.
- Simplified log message construction in loggers.
- Enhanced JSON log parsing in `PrettyHandler`.
- Optimized `ColorLogger` methods for performance.
- Updated `NewPrettyHandler` for structured formatting and colorization.
- Refined `Handle` method in `PrettyHandler` for improved log processing.
- Added `outputToFile`, `outputJSON`, and `outputFormatted` methods in `PrettyHandler`.
- Introduced `parseLogRecord` and `colorizeBasedOnLevel` methods in `PrettyHandler`.

**Removed:**
- Redundant `Close()` method from loggers.
- Obsolete code and comments from PrettyHandler.
- Unused imports for streamlined code.

**Fixed:**
- Color codes issue in JSON output and random {} in color output.
- Corrected test assertion logic in PrettyHandler tests.
- Resolved SC2207 ShellCheck warnings.
- Addressed go vet and test script issues in CI.
- Fixed markdown formatting in `README.md`.

**Performance Improvements:**
- Increased pre-commit run speed and script robustness.

1499 of 2221 relevant lines covered (67.49%)

11.97 hits per line

Jobs
ID Job ID Ran Files Coverage
1 7422663882.1 05 Jan 2024 01:58PM UTC 0
67.49
GitHub Action Run
Source Files on build 7422663882
Detailed source file information is not available for this build.
  • Back to Repo
  • a1f8f0b4 on github
  • Prev Build on main (#7422429871)
  • Next Build on main (#7434107005)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc