Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Feature/test code lint fix#33

Merged
langowarny merged 2 commits intodevfrom
feature/test-code-lint-fix
Feb 28, 2026
Merged

Feature/test code lint fix#33
langowarny merged 2 commits intodevfrom
feature/test-code-lint-fix

Conversation

@langowarny
Copy link
Collaborator

  • refactor: improve error handling and logging consistency
  • test: increase TTL duration in session store tests for improved reliability

…bility

- Updated TTL from 1ms to 50ms in TestEntStore_TTL and TestEntStore_TTL_DeleteAndRecreate.
- Adjusted sleep duration from 5ms to 100ms to ensure sessions expire correctly during tests.
- Updated various defer statements to handle errors silently using `_ =` for functions like `logging.Sync()`, `resp.Body.Close()`, and `node.Stop()`, ensuring that potential errors do not disrupt execution flow.
- Replaced string formatting with `fmt.Fprintf` for better performance and consistency in string building across multiple files.
- Removed deprecated code and unnecessary comments to streamline the codebase.
- Enhanced JSON response handling in HTTP handlers by introducing a `writeJSON` utility function for cleaner and more maintainable code.
@langowarny langowarny self-assigned this Feb 28, 2026
@langowarny langowarny added the bug Something isn't working label Feb 28, 2026
@langowarny langowarny merged commit 523c753 into dev Feb 28, 2026
@langowarny langowarny deleted the feature/test-code-lint-fix branch February 28, 2026 18:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant